1
0
mirror of https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git synced 2024-12-01 09:43:09 +00:00
os-autoinst-distri-fedora/tests/windows_install.pm

116 lines
3.1 KiB
Perl
Raw Permalink Normal View History

2019-11-01 15:00:30 +00:00
use base "anacondatest";
use strict;
use testapi;
use utils;
sub run {
my $self = shift;
# Check whether we have arrived in the main installation screen.
2019-11-05 12:12:33 +00:00
assert_screen("win_setup_main", timeout=>300); #
2019-11-01 15:00:30 +00:00
# Set up keyboard layouts or languages. For our purposes, a simple
# click on the Next button will do.
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_next";
2019-11-01 15:00:30 +00:00
# Start installation
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_install";
2019-11-01 15:00:30 +00:00
# Accept the EULA.
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_eula_accept";
assert_and_click "win_setup_next";
2019-11-01 15:00:30 +00:00
# Select the custom installation
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_custom_install";
2019-11-01 15:00:30 +00:00
# The drive 0 will always be empty, so just click Next to continue
2019-11-05 12:12:33 +00:00
assert_and_click "win_setup_next",;
2019-11-01 15:00:30 +00:00
# Confirm the region, the default US region will be ok.
2019-11-05 12:12:33 +00:00
assert_and_click("win_setup_yes", timeout=>600);
# Confirm the keyboard layout, the default US keyboard will be ok.
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_yes";
# Skip adding the second keyboard, we are not interested anyway.
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_skip";
2019-11-01 15:00:30 +00:00
2019-11-05 13:48:49 +00:00
# If no internet is detected, deal with no internet else connect
# to a local domain.
2019-11-05 11:55:58 +00:00
2019-11-05 14:06:38 +00:00
if (check_screen("win_setup_no_internet", timeout=>120)) {
2019-11-05 13:48:49 +00:00
assert_and_click "win_setup_dont_have_net";
assert_and_click "win_setup_limited";
} else {
# Join a local domain
assert_and_click("win_setup_local_account");
}
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
2019-11-01 15:00:30 +00:00
# Fill-in the account name
2019-11-05 14:18:00 +00:00
assert_and_click "win_setup_select_username";
sleep 1;
type_very_safely "Fedora";
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
# Fill-in the password
2019-11-05 14:18:00 +00:00
assert_and_click "win_setup_select_password";
sleep 1;
type_very_safely "weakpassword";
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
# Confirm the password
2019-11-05 14:18:00 +00:00
assert_and_click "win_setup_select_password";
sleep 1;
type_very_safely "weakpassword";
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
# Deal with security questions
# What was your first pet's name?
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_security_question";
assert_and_click "win_setup_your_pet";
sleep 1;
2019-11-01 15:00:30 +00:00
send_key "tab";
sleep 1;
type_very_safely "Bob";
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
# What was your childhood nickname?
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_security_question";
assert_and_click "win_setup_childhood_nickname";
sleep 1;
2019-11-01 15:00:30 +00:00
send_key "tab";
sleep 1;
type_very_safely "Bob";
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
# What was the name of your oldest cousin?
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_security_question";
assert_and_click "win_setup_oldest_cousin";
sleep 1;
2019-11-01 15:00:30 +00:00
send_key "tab";
sleep 1;
type_very_safely "Bob";
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_bluenext";
# Refuse the activity history.
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_blueno";
# Refuse digital assistant
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_decline";
# Accept suggested values (bad but fast and easy)
2019-11-05 12:08:25 +00:00
assert_and_click "win_setup_accept";
2019-11-01 15:00:30 +00:00
# Check if booted
2019-11-05 14:30:14 +00:00
assert_screen("win_setup_booted_logged", timeout=>600);
2019-11-01 15:00:30 +00:00
}
sub test_flags {
return { fatal => 1 };
}
1;
# vim: set sw=4 et: