mirror of
https://github.com/rocky-linux/os-autoinst-distri-rocky.git
synced 2024-11-18 03:01:26 +00:00
84a14cdb67
This requires adding products, flavors and needles and test cases, and tweaking some existing ones to handle the slightly different behaviour of live images in shared tests. To handle the different main hub screens in live and non-live, a less stringent needle is added which is unregistered for non-live tests, so they don't match on it before they've finished updating repository metadata. There are a few small bugfix tweaks in this too, like some delays in user creation to try and avoid intermittent failures there. A new root_logged_in needle is also included, to handle a new console font in Rawhide - that has nothing strictly to do with live testing, it just happened to come up while working on this.
58 lines
1.6 KiB
Perl
58 lines
1.6 KiB
Perl
use base "anacondalog";
|
|
use strict;
|
|
use testapi;
|
|
|
|
sub run {
|
|
# Anaconda hub
|
|
assert_screen "anaconda_main_hub", 300; #
|
|
|
|
# Begin installation
|
|
assert_and_click "anaconda_main_hub_begin_installation";
|
|
|
|
# Set root password
|
|
my $root_password = get_var("ROOT_PASSWORD") || "weakpassword";
|
|
assert_and_click "anaconda_install_root_password";
|
|
type_string $root_password;
|
|
send_key "tab";
|
|
type_string $root_password;
|
|
assert_and_click "anaconda_spoke_done";
|
|
# weak password - click "done" once again"
|
|
#assert_and_click "anaconda_spoke_done";
|
|
|
|
# Set user details
|
|
sleep 1;
|
|
my $user_login = get_var("USER_LOGIN") || "test";
|
|
my $user_password = get_var("USER_PASSWORD") || "weakpassword";
|
|
assert_and_click "anaconda_install_user_creation";
|
|
type_string $user_login;
|
|
send_key "tab";
|
|
send_key "tab";
|
|
send_key "tab";
|
|
send_key "tab";
|
|
type_string $user_password;
|
|
send_key "tab";
|
|
type_string $user_password;
|
|
assert_and_click "anaconda_install_user_creation_make_admin";
|
|
assert_and_click "anaconda_spoke_done";
|
|
# weak password - click "done" once again"
|
|
#assert_and_click "anaconda_spoke_done";
|
|
|
|
# Wait for install to end
|
|
assert_and_click "anaconda_install_done", '', 1800;
|
|
if (get_var('LIVE')) {
|
|
x11_start_program("reboot");
|
|
}
|
|
}
|
|
|
|
sub test_flags {
|
|
# without anything - rollback to 'lastgood' snapshot if failed
|
|
# 'fatal' - whole test suite is in danger if this fails
|
|
# 'milestone' - after this test succeeds, update 'lastgood'
|
|
# 'important' - if this fails, set the overall state to 'fail'
|
|
return { fatal => 1 };
|
|
}
|
|
|
|
1;
|
|
|
|
# vim: set sw=4 et:
|