test(sweep): add modal-pin-setup/-change/-remove capture surfaces
Register the three redesigned PIN dialogs as sweep surfaces for visual review. Each setup only sets the show flag (never fires the async vault store/verify); the teardown clears the status and zeroes the PIN/passphrase buffers. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -302,6 +302,29 @@ void App::buildSweepCatalog()
|
||||
a.show_decrypt_dialog_ = false; a.wallet_security_workflow_.reset();
|
||||
memset(a.decrypt_pass_buf_, 0, sizeof(a.decrypt_pass_buf_));
|
||||
});
|
||||
// PIN setup / change / remove dialogs (never fire the async vault store/verify).
|
||||
add("modal-pin-setup", ui::NavPage::Settings,
|
||||
[](App& a) { a.show_pin_setup_ = true; },
|
||||
[](App& a) {
|
||||
a.show_pin_setup_ = false; a.pin_status_.clear();
|
||||
memset(a.pin_passphrase_buf_, 0, sizeof(a.pin_passphrase_buf_));
|
||||
memset(a.pin_buf_, 0, sizeof(a.pin_buf_));
|
||||
memset(a.pin_confirm_buf_, 0, sizeof(a.pin_confirm_buf_));
|
||||
});
|
||||
add("modal-pin-change", ui::NavPage::Settings,
|
||||
[](App& a) { a.show_pin_change_ = true; },
|
||||
[](App& a) {
|
||||
a.show_pin_change_ = false; a.pin_status_.clear();
|
||||
memset(a.pin_old_buf_, 0, sizeof(a.pin_old_buf_));
|
||||
memset(a.pin_buf_, 0, sizeof(a.pin_buf_));
|
||||
memset(a.pin_confirm_buf_, 0, sizeof(a.pin_confirm_buf_));
|
||||
});
|
||||
add("modal-pin-remove", ui::NavPage::Settings,
|
||||
[](App& a) { a.show_pin_remove_ = true; },
|
||||
[](App& a) {
|
||||
a.show_pin_remove_ = false; a.pin_status_.clear();
|
||||
memset(a.pin_old_buf_, 0, sizeof(a.pin_old_buf_));
|
||||
});
|
||||
add("modal-about", ui::NavPage::Overview,
|
||||
[](App& a) { a.show_about_ = true; }, [](App& a) { a.show_about_ = false; });
|
||||
add("modal-settings", ui::NavPage::Settings,
|
||||
|
||||
Reference in New Issue
Block a user