1
0
mirror of https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git synced 2024-11-18 12:33:09 +00:00
os-autoinst-distri-fedora/tests/_boot_to_anaconda.pm
Adam Williamson 84a14cdb67 Support for live image testing
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.
2015-03-18 14:28:03 -07:00

72 lines
1.9 KiB
Perl

use base "anacondalog";
use strict;
use testapi;
sub run {
# Wait for bootloader to appear
assert_screen "bootloader", 30;
# Make sure we skip media check if it's selected by default. Standard
# 'boot installer' menu entry is always first.
send_key "up";
send_key "up";
if( get_var("GRUB")){
send_key "tab";
type_string " ".get_var("GRUB");
}
if (get_var("REPOSITORY_VARIATION")){
unless (get_var("GRUB")){
send_key "tab";
}
my $fedora_version = "";
my $repourl = "";
$fedora_version = lc((split /_/, get_var("BUILD"))[0]);
$repourl = get_var("REPOSITORY_VARIATION")."/".$fedora_version."/".get_var("ARCH")."/os";
type_string " inst.repo=".$repourl;
}
send_key "ret";
unless (get_var("KICKSTART"))
{
# on lives, we have to explicitly launch anaconda
if (get_var('LIVE')) {
assert_and_click "live_initial_anaconda_launcher", '', 300;
} else {
assert_screen "anaconda_select_install_lang", 300;
}
# Select install language
assert_and_click "anaconda_select_install_lang_input";
type_string "english";
assert_and_click "anaconda_select_install_lang_english_filtered";
assert_screen "anaconda_select_install_lang_english_selected", 3;
assert_and_click "anaconda_select_install_lang_continue";
if ( check_screen "anaconda_rawhide_accept_fate" ) {
assert_and_click "anaconda_rawhide_accept_fate";
}
# Anaconda hub
assert_screen "anaconda_main_hub", 900; #
}
}
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: