mirror of
https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git
synced 2025-06-26 00:11:39 +00:00
The previous version of menu_launch_type took the name of the application as an argument and it started the application. To maximize the application or to check that it has started indeed we had to do it manually. Now, the application also takes "maximize => 1" or "checkstart => 1" to maximize the application or check that it has started as optional arguments to avoid doing it manually, while it still accepts just the name of the application and behaves like it did before. Note that if you decide to use the checkstart argument, you also need to update the check-needles.py script to whitelist the application needle tag, see the example test scripts attached to this PR. Fixes: https://pagure.io/fedora-qa/os-autoinst-distri-fedora/issue/329
38 lines
1012 B
Perl
38 lines
1012 B
Perl
use base "installedtest";
|
|
use strict;
|
|
use testapi;
|
|
use utils;
|
|
|
|
# This will set up the environment for the archiver test.
|
|
# It creates nine file and places them in the Documents folder.
|
|
# Then opens Nautilus (archive fce) and switches to that folder.
|
|
|
|
sub run {
|
|
my $self = shift;
|
|
my $username = get_var("USER_LOGIN") // "test";
|
|
# Create the files on the CLI
|
|
$self->root_console(tty => 3);
|
|
assert_script_run("cd /home/$username/Documents");
|
|
assert_script_run('for i in {1..9}; do echo $i > file$i.txt; done');
|
|
assert_script_run("chown -R $username:$username /home/$username/Documents/");
|
|
# Exit to the GUI
|
|
desktop_vt;
|
|
|
|
# Set the update notification timestamp
|
|
set_update_notification_timestamp();
|
|
|
|
# Start the application
|
|
menu_launch_type("nautilus", checkstart => 1, maximize => 1);
|
|
|
|
# Open the Documents directory
|
|
assert_and_click("gnome_open_location_documents");
|
|
}
|
|
|
|
sub test_flags {
|
|
return {fatal => 1, milestone => 1};
|
|
}
|
|
|
|
1;
|
|
|
|
# vim: set sw=4 et:
|