Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move the vagrant tests out of the virtualization group #8883

Merged
merged 1 commit into from
Nov 26, 2019

Conversation

dcermak
Copy link
Contributor

@dcermak dcermak commented Nov 11, 2019

@dcermak
Copy link
Contributor Author

dcermak commented Nov 13, 2019

Ok, I have honestly no idea how to make a test run for this. openqa-clone-custom-refspec doesn't work here, because I cannot clone this job.

Help?

@foursixnine
Copy link
Member

Ok, I have honestly no idea how to make a test run for this. openqa-clone-custom-refspec doesn't work here, because I cannot clone this job.

I guess you can't clone it, because the job doesn't exist yet right? if so you can always start off a pre existing job:

openqa-clone-custom-git-refspec https://github.com/os-autoinst/os-autoinst-distri-opensuse/pull/8883 https://openqa.opensuse.org/tests/1084317\
 SCHEDULE=tests/boot/boot_to_desktop,\
tests/virtualization/vagrant/add_box_virtualbox,\
tests/virtualization/vagrant/add_box_libvirt,\
tests/virtualization/vagrant/boxes/tumbleweed

As for how to make sure it is properly added, by using the extra_tests mechanism:

You will need to create the test suite in o3, extra_tests_vagrant would be a good candidate (but you can choose your own, or the name provided by @DimStar77), next you could copy the settings from a similar extra test, eg extra_tests_dracut or use the virtualization test suite and ensure that the EXTRATEST has the correct setting, EXTRATEST=vagrant and possibly update the START_AFTER_TEST, HDD_1, etc.

After this is done, rename and move load_vagrant_tests to load_extra_tests_vagrant

To verify that it works, you can use again the openqa-clone-custom-git-refspec:

openqa-clone-custom-git-refspec https://github.com/os-autoinst/os-autoinst-distri-opensuse/pull/8883 https://openqa.opensuse.org/tests/1084317 EXTRATEST=vagrant

Note that you could chain up multiple extratests in the same run

Help?

Ping me here or IRC :)

@DimStar77
Copy link
Contributor

You will need to create the test suite in o3, extra_tests_vagrant would be a good candidate (but you can choose your own, or the name provided by @DimStar77)

extra_tests_vagrant sounds reasonable as a name for the new test

@DimStar77
Copy link
Contributor

oh - preferably we would chain that behind create_hdd_textmode, as vagrant, as far as I understood so far, does not require a X Server/GUI - so having it behind GNOME (like virtualization) can be avoided

Copy link
Member

@foursixnine foursixnine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm against moving the vagrant tests out of the physical directory.

@@ -50,7 +50,7 @@ sub run() {
#
# get Vagrantfile template and replace the distro name & insert box filenames
#
assert_script_run("wget --quiet " . data_url("virtualization/Vagrantfile"));
assert_script_run("wget --quiet " . data_url("vagrant/Vagrantfile"));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would rather recommend to move your files to virtualization/vagrant so that the scope is clearer, the same applies for the .pm files. At this moment most of the directories under /tests/ help to organize the test modules by domain (although this seems to be an unwritten rule), and to me, vagrant falls inside the virtualization domain :).

Can we not move it? (At the test suite level/job group, I don't care much)

@foursixnine
Copy link
Member

As a bonus: https://openqa.opensuse.org/tests/1084439#

@dcermak dcermak force-pushed the splitout_vagrant_tests branch 4 times, most recently from 1c89241 to cfc8047 Compare November 22, 2019 14:27
@dcermak
Copy link
Contributor Author

dcermak commented Nov 22, 2019

I think the tests should work in the current state (local test run is currently in progress), but they require the following prerequisites on o3:

  • Create a new test suite extra_tests_vagrant with the following variables:
BOOT_HDD_IMAGE=1
DESKTOP=textmode
HDD_1=%DISTRI%-%VERSION%-%ARCH%-%BUILD%-%DESKTOP%@%MACHINE%.qcow2
QEMUCPU=host
START_AFTER_TEST=create_hdd_textmode
UEFI_PFLASH_VARS=%DISTRI%-%VERSION%-%ARCH%-%BUILD%-%DESKTOP%@%MACHINE%-uefi-vars.qcow2
VAGRANT=1

and the description:

Maintainer: dancermak. Test vagrant, vagrant plugins and the vagrant boxes.	
  • add the test suite to the job group openSUSE Tumbleweed:
     - upgrade_Leap_42.3_cryptlvm:
         machine: uefi
+    - extra_tests_vagrant
     - virtualization

@dcermak dcermak marked this pull request as ready for review November 22, 2019 14:48
@DimStar77
Copy link
Contributor

I think the tests should work in the current state (local test run is currently in progress), but they require the following prerequisites on o3:

I set this up in o3 and added the scenario to the Tumbleweed Development Group.

@@ -429,6 +429,7 @@ else {
|| load_qam_install_tests()
|| load_extra_tests()
|| load_virtualization_tests()
|| load_vagrant_tests()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should add to your test suite:

EXTRATEST=vagrant and this line won't be needed (And also VAGRANT=1 can be removed). Please re-read my comment from my previous review regarding the extratests mechanism or give it a look here to se how it works :)

If you decide to not use the extratests mechanism, please document the variable in variables.md.

@dcermak
Copy link
Contributor Author

dcermak commented Nov 22, 2019

@foursixnine I've tried to use a declarative schedule instead and it appears to do the right thing (TM) on my local machine (the test run didn't finish yet though, it just scheduled the right tests).

@foursixnine
Copy link
Member

@foursixnine I've tried to use a declarative schedule instead and it appears to do the right thing (TM) on my local machine (the test run didn't finish yet though, it just scheduled the right tests).

Even better :D

@dcermak
Copy link
Contributor Author

dcermak commented Nov 22, 2019

My local testrun was successful and I have updated the test suite settings for extra_tests_vagrant on o3, so it should work now.

@foursixnine
Copy link
Member

@dcermak I guess this is done & ready to merge?

@dcermak
Copy link
Contributor Author

dcermak commented Nov 26, 2019

I have anything to add to this PR, beside my sincere apologies if it breaks something ;-).

@foursixnine foursixnine merged commit c49858c into os-autoinst:master Nov 26, 2019
@dcermak dcermak deleted the splitout_vagrant_tests branch November 26, 2019 15:51
@dcermak
Copy link
Contributor Author

dcermak commented Nov 27, 2019

Test is scheduled to run on o3: https://openqa.opensuse.org/tests/1096936

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants