1
0
mirror of https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git synced 2024-12-27 12:43:08 +00:00
os-autoinst-distri-fedora/tests/apps_startstop/kde/vault.pm
Adam Williamson adedf40b6f apps_startstop: don't rollback, defend against KDE mistypes
This comes from trying to fix the annoying recurring problem with
mistypes in KDE which has been going on since at least December.
First, we add the attempt to kind of 'precache' the kicker menu
in aasetting.pm. Then, I thought, all this snapshot loading has
to be putting a lot of load on the workers. And when each subtest
passes, it shouldn't really be necessary - they all end with
quit_with_shortcut(), which verifies that the app exited and we
got back to a blank desktop, so successful subtests should not
usually interfere with each other. We probably only want to
rollback on *failed* subtests, which is in fact openQA's default
behavior. There only seems to be one case where a test changes the
system state such that later tests might be affected, so I kept
always_rollback just for that one. I've run this through three
cycles on GNOME and KDE and it looks good.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
2024-04-12 15:53:48 -07:00

79 lines
2.0 KiB
Perl

use base "installedtest";
use strict;
use testapi;
use utils;
# This test checks that Vault starts.
sub run {
my $self = shift;
# As there are no vaults created, we need to list
# invisible icons.
assert_and_click "desktop_expand_systray";
# Now we should be able to see the Vaults icon,
# so we will click on it.
assert_and_click "vault_menu_open";
# This is a new installation so there, should not be
# any existing vaults. Let's check for it.
assert_screen "vault_menu_not_exist";
# Click on Create a New ... to start the vault creation
assert_and_click "vault_menu_create_new";
# A vault creation dialog should appear
assert_screen "vault_dialog_runs";
# Check that a correct backend is available
assert_screen "vault_backend_available";
# Enter the name of the newly created testvault
assert_and_click "vault_enter_name";
# Then name the vault "testvault"
type_very_safely "testvault";
# Click the Next button
assert_and_click "kde_next";
# If the security notice appears, click next it away.
if (check_screen "vault_security_notice") {
assert_and_click "kde_next";
}
# Enter a password and validate it.
assert_and_click "vault_enter_password";
type_very_safely "SecretVaultCode";
send_key "tab";
type_very_safely "SecretVaultCode";
assert_and_click "kde_next";
# Check that a mountpount screen appears
assert_screen "vault_mountpoint";
# Click Next to confirm
assert_and_click "kde_next";
# Click on Create to make it happen
assert_and_click "vault_create";
# Now the vault should be created so let us check, that it really
# got created.
# There should be a new small vault icon visible in the tray, so let's
# click that to open the vault menu.
assert_and_click "vault_tray_icon";
# Check that the vault is listed in the overview
assert_screen "vault_new_created";
}
sub test_flags {
return {};
}
1;
# vim: set sw=4 et: