Add initial CoreOS product and test templates

Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
Adam Williamson 2020-08-19 14:58:02 -07:00
parent 170ef0733a
commit 478b7eff9e
5 changed files with 58 additions and 6 deletions

View File

@ -466,9 +466,10 @@ sub setup_workaround_repo {
}
sub _repo_setup_compose {
# doesn't work for IoT, anything that hits this in an IoT path
# must work with default mirror config...
return if (get_var("SUBVARIANT") eq "IoT");
# doesn't work for IoT or CoreOS, anything that hits this on those
# paths must work with default mirror config...
my $subvariant = get_var("SUBVARIANT");
return if ($subvariant eq "IoT" || $subvariant eq "CoreOS");
# Appropriate repo setup steps for testing a compose
# disable updates-testing and updates and use the compose location
# as the target for fedora and rawhide rather than mirrorlist, so

View File

@ -134,6 +134,11 @@ sub load_upgrade_tests() {
}
sub load_install_tests() {
# CoreOS is special, so we handle that here
if (get_var("SUBVARIANT") eq "CoreOS") {
autotest::loadtest "tests/_coreos_install.pm";
return;
}
# normal installation test consists of several phases, from which some of them are
# loaded automatically and others are loaded based on what env variables are set

View File

@ -115,6 +115,17 @@
},
"version": "*"
},
"fedora-CoreOS-colive-iso-x86_64-*": {
"arch": "x86_64",
"distri": "fedora",
"flavor": "CoreOS-colive-iso",
"settings": {
"CANNED": "1",
"TEST_TARGET": "ISO",
"USER_LOGIN": "false"
},
"version": "*"
},
"fedora-Everything-boot-iso-ppc64le-*": {
"arch": "ppc64le",
"distri": "fedora",
@ -323,6 +334,10 @@
"machine": "64bit",
"product": "fedora-Cloud_Base-qcow2-qcow2-x86_64-*"
},
"fedora-CoreOS-colive-iso-x86_64-*-64bit": {
"machine": "64bit",
"product": "fedora-CoreOS-colive-iso-x86_64-*"
},
"fedora-Everything-boot-iso-ppc64le-*-ppc64le": {
"machine": "ppc64le",
"product": "fedora-Everything-boot-iso-ppc64le-*"
@ -448,6 +463,7 @@
},
"base_reboot_unmount": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 20,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 20,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 20,
"fedora-KDE-live-iso-x86_64-*-64bit": 22,
@ -480,6 +496,7 @@
},
"base_system_logging": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 20,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 20,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 20,
"fedora-KDE-live-iso-x86_64-*-64bit": 22,
@ -540,6 +557,7 @@
},
"base_services_start": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 40,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 40,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 40,
"fedora-KDE-live-iso-x86_64-*-64bit": 42,
@ -586,6 +604,7 @@
},
"base_selinux": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 40,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 40,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 40,
"fedora-KDE-live-iso-x86_64-*-64bit": 42,
@ -618,6 +637,7 @@
},
"base_service_manipulation": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 40,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 40,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 40,
"fedora-KDE-live-iso-x86_64-*-64bit": 42,
@ -986,6 +1006,7 @@
},
"install_default_upload": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 20,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 20,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 20,
"fedora-KDE-live-iso-x86_64-*-64bit": 15,
@ -1704,6 +1725,7 @@
},
"podman": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 20,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 20,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 40
},
@ -1721,6 +1743,7 @@
},
"podman_client": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 20,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 20,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 40
},
@ -1777,6 +1800,7 @@
},
"release_identification": {
"profiles": {
"fedora-CoreOS-colive-iso-x86_64-*-64bit": 20,
"fedora-IoT-dvd_ostree-iso-aarch64-*-aarch64": 20,
"fedora-IoT-dvd_ostree-iso-x86_64-*-64bit": 20,
"fedora-KDE-live-iso-x86_64-*-64bit": 50,

20
tests/_coreos_install.pm Normal file
View File

@ -0,0 +1,20 @@
use base "installedtest";
use strict;
use testapi;
use utils;
sub run {
my $self = shift;
assert_screen "user_console", 300;
type_string "sudo su\n";
assert_script_run "coreos-installer install /dev/vda --ignition-url https://www.happyassassin.net/temp/openqa.ign", 600;
type_string "reboot\n";
}
sub test_flags {
return { fatal => 1 };
}
1;
# vim: set sw=4 et:

View File

@ -28,9 +28,11 @@ sub run {
validate_script_output "podman container ls", sub { m/fedora-httpd/ };
# Test apache is working
assert_script_run "curl http://localhost";
# Open the firewall
assert_script_run "firewall-cmd --permanent --zone=internal --add-interface=cni-podman0";
assert_script_run "firewall-cmd --permanent --zone=internal --add-port=80/tcp";
# Open the firewall, except on CoreOS where it's not installed
unless (get_var("SUBVARIANT") eq "CoreOS") {
assert_script_run "firewall-cmd --permanent --zone=internal --add-interface=cni-podman0";
assert_script_run "firewall-cmd --permanent --zone=internal --add-port=80/tcp";
}
# tell client we're ready and wait for it to send the message
mutex_create("podman_server_ready");
my $children = get_children();