From 33fd05f3d0d3f94dc88fffa48b299cffcf8a6617 Mon Sep 17 00:00:00 2001 From: Guy Menanteau Date: Mon, 4 Feb 2019 14:46:31 +0000 Subject: [PATCH] New install_repository_nfsiso_variation This is covering the NFSISO_variation test as per: https://fedoraproject.org/wiki/QA:Testcase_install_repository_NFSISO_variation Change support_server to use support_5 disk image in templates supposed to be previously created by updated createhdds tool required for new test. Signed-off-by: Guy Menanteau --- templates | 47 +++++++++++++++++++++++++++++++++- tests/_check_install_source.pm | 5 ++++ tests/_support_server.pm | 6 ++++- 3 files changed, 56 insertions(+), 2 deletions(-) diff --git a/templates b/templates index 07b171da..7a74390c 100755 --- a/templates +++ b/templates @@ -710,6 +710,17 @@ }, test_suite => { name => "install_repository_nfs_graphical" }, }, + { + machine => { name => "64bit" }, + prio => 30, + product => { + arch => "x86_64", + distri => "fedora", + flavor => "Server-dvd-iso", + version => "*", + }, + test_suite => { name => "install_repository_nfsiso_variation" }, + }, { machine => { name => "64bit" }, prio => 30, @@ -2135,6 +2146,18 @@ }, test_suite => { name => "install_repository_nfs_graphical" }, }, + { + group_name => "Fedora PowerPC", + machine => { name => "ppc64le" }, + prio => 30, + product => { + arch => "ppc64le", + distri => "fedora", + flavor => "Server-dvd-iso", + version => "*", + }, + test_suite => { name => "install_repository_nfsiso_variation" }, + }, { group_name => "Fedora PowerPC", machine => { name => "ppc64le" }, @@ -3767,6 +3790,18 @@ }, test_suite => { name => "install_repository_nfs_graphical" }, }, + { + group_name => "Fedora AArch64", + machine => { name => "aarch64" }, + prio => 30, + product => { + arch => "aarch64", + distri => "fedora", + flavor => "Server-dvd-iso", + version => "*", + }, + test_suite => { name => "install_repository_nfsiso_variation" }, + }, { group_name => "Fedora AArch64", machine => { name => "aarch64" }, @@ -4831,7 +4866,7 @@ settings => [ { key => "PARALLEL_CANCEL_WHOLE_CLUSTER", value => "0" }, { key => "NUMDISKS", value => "2" }, - { key => "HDD_1", value => "disk_f%CURRREL%_support_4_%ARCH%.img" }, + { key => "HDD_1", value => "disk_f%CURRREL%_support_5_%ARCH%.img" }, { key => "POSTINSTALL", value => "_support_server" }, { key => "USER_LOGIN", value => "false" }, { key => "ROOT_PASSWORD", value => "weakpassword" }, @@ -4976,6 +5011,16 @@ { key => "WORKER_CLASS", value => "tap" }, ], }, + { + name => "install_repository_nfsiso_variation", + settings => [ + { key => "REPOSITORY_VARIATION", value => "nfs:nfsvers=4:10.0.2.110:/iso/image.iso" }, + { key => "PARALLEL_WITH", value => "support_server" }, + { key => "INSTALL_UNLOCK", value => "support_ready" }, + { key => "NICTYPE", value => "tap" }, + { key => "WORKER_CLASS", value => "tap" }, + ], + }, { name => "install_repository_hd_variation", settings => [ diff --git a/tests/_check_install_source.pm b/tests/_check_install_source.pm index 09efb72f..359549c5 100644 --- a/tests/_check_install_source.pm +++ b/tests/_check_install_source.pm @@ -2,6 +2,7 @@ use base "anacondatest"; use strict; use testapi; use anaconda; +use File::Basename; sub run { my $self = shift; @@ -38,6 +39,10 @@ sub run { $repourl =~ s/^nfsvers=.://; # the above both checks if we're dealing with an NFS URL, and # strips the 'nfs:' and 'nfsvers=.:' from it if so + # remove image.iso name when dealing with nfs iso + if ($repourl =~ /\.iso/) { + $repourl = dirname $repourl; + } # check the repo was actually mounted assert_script_run "mount |grep nfs |grep '${repourl}'"; } diff --git a/tests/_support_server.pm b/tests/_support_server.pm index 63ca65f0..face9a38 100644 --- a/tests/_support_server.pm +++ b/tests/_support_server.pm @@ -50,8 +50,12 @@ sub run { # put the updates image in the NFS repo (for testing this update # image delivery method) assert_script_run "curl -o /repo/images/updates.img https://fedorapeople.org/groups/qa/updates/updates-openqa.img"; + # create the iso share + assert_script_run "mkdir -p /iso"; + # recreate an iso file + copy_devcdrom_as_isofile('/iso/image.iso'); # set up the exports - assert_script_run "printf '/export 10.0.2.0/24(ro)\n/repo 10.0.2.0/24(ro)' > /etc/exports"; + assert_script_run "printf '/export 10.0.2.0/24(ro)\n/repo 10.0.2.0/24(ro)\n/iso 10.0.2.0/24(ro)' > /etc/exports"; } # open firewall port