Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- alfano:/var/lib/openqa/tests/kubic/products/kubic/:[0]# tree
- .
- |-- main.pm
- |-- needles -> ../opensuse/needles
- `-- testsuites
- |-- microos_10G.pm
- |-- microos.pm
- |-- microos_uefi.pm
- `-- rcshell.pm
- 2 directories, 5 files
- alfano:/var/lib/openqa/tests/kubic/products/kubic/:[0]# less main.pm
- alfano:/var/lib/openqa/tests/kubic/products/kubic/:[0]#
- alfano:/var/lib/openqa/tests/kubic/products/kubic/:[0]# cat main.pm
- use strict;
- use warnings;
- use testapi qw(check_var get_var get_required_var set_var);
- use needle;
- use File::Basename;
- BEGIN {
- unshift @INC, dirname(__FILE__) . '/../../lib';
- unshift @INC, dirname(__FILE__) . '/testsuites';
- }
- use utils;
- use main_common;
- # Kubic Testsuites
- use microos;
- use microos_uefi;
- use microos_10G;
- use rcshell;
- init_main();
- my $distri = testapi::get_required_var('CASEDIR') . '/lib/susedistribution.pm';
- require $distri;
- testapi::set_distribution(susedistribution->new());
- set_var 'FAIL_EXPECTED', 'SMALL-DISK' if get_var('HDDSIZEGB') < 12;
- # Which jobgroup the testsuites belong
- sub jobgroup {
- my $filter = shift;
- return 1 unless $filter;
- if ($filter eq 'Tumbleweed kubic-dvd') {
- return ((check_var 'VERSION', 'Tumbleweed') && (check_var 'DISTRI', 'kubic') && (check_var 'FLAVOR', 'DVD'))
- }
- }
- # When a testsuite should be triggered
- sub testsuite {
- my $filter = shift;
- return 1 unless $filter;
- if ($filter eq 'rcshell') {
- return (check_var 'TEST', 'rcshell');
- }
- if ($filter eq 'microos@64bit-4G-HD40G') {
- return ((check_var 'TEST', 'microos') && !(get_var 'UEFI'));
- }
- if ($filter eq 'microos@uefi-4G-HD40G') {
- return ((check_var 'TEST', 'microos') && (check_var 'UEFI', '1'));
- }
- if ($filter eq 'microos_10G-disk') {
- return (check_var 'TEST', 'microos_10G-disk');
- }
- }
- if (jobgroup 'Tumbleweed kubic-dvd') {
- rcshell::run_tests if testsuite('rcshell');
- microos::run_tests if testsuite('microos@64bit-4G-HD40G');
- microos_uefi::run_tests if testsuite('microos@uefi-4G-HD40G');
- microos_10G::run_tests if testsuite('microos_10G-disk');
- }
- 1;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement