nixos/keepassxc: adapt to new UI details

There now is a "Refresh Hardware Keys" icon since 2.7.7, which we have to skip.
I also needed to add more explicit handling of the intermediate file dialog to
get the test to pass.
This commit is contained in:
amesgen 2024-11-06 01:56:08 +01:00
parent c8c430ecf9
commit c712874d4a
No known key found for this signature in database
GPG Key ID: 1A89EC203635A13D

View File

@ -67,10 +67,21 @@ import ./make-test-python.nix ({ pkgs, ...} :
# Wait for the enter password screen to appear.
machine.wait_for_text("/home/alice/foo.kdbx")
# Click on "Browse" button to select keyfile
# Click on "I have key file" button to open keyfile dialog
machine.send_key("tab")
machine.send_key("tab")
machine.send_key("tab")
machine.send_key("ret")
# Select keyfile
machine.wait_for_text("Select key file")
machine.send_chars("/home/alice/foo.keyfile")
machine.send_key("ret")
# Open database
machine.wait_for_text("foo.kdbx \\[Locked] - KeePassXC")
machine.send_key("ret")
# Database is unlocked (doesn't have "[Locked]" in the title anymore)
machine.wait_for_text("foo.kdbx - KeePassXC")
'';