Commit 0f8d12ab authored by Bjorn Munch's avatar Bjorn Munch

merge 54364

parents 711ce776 b27f1478
...@@ -124,7 +124,7 @@ sub mtr_report_test ($) { ...@@ -124,7 +124,7 @@ sub mtr_report_test ($) {
my $timest = format_time(); my $timest = format_time();
my $fail = "fail"; my $fail = "fail";
if ( $::opt_experimental ) if ( @$::experimental_test_cases )
{ {
# Find out if this test case is an experimental one, so we can treat # Find out if this test case is an experimental one, so we can treat
# the failure as an expected failure instead of a regression. # the failure as an expected failure instead of a regression.
......
...@@ -187,7 +187,7 @@ our $opt_client_debugger; ...@@ -187,7 +187,7 @@ our $opt_client_debugger;
my $config; # The currently running config my $config; # The currently running config
my $current_config_name; # The currently running config file template my $current_config_name; # The currently running config file template
our $opt_experimental; our @opt_experimentals;
our $experimental_test_cases; our $experimental_test_cases;
my $baseport; my $baseport;
...@@ -847,7 +847,7 @@ sub command_line_setup { ...@@ -847,7 +847,7 @@ sub command_line_setup {
'big-test' => \$opt_big_test, 'big-test' => \$opt_big_test,
'combination=s' => \@opt_combinations, 'combination=s' => \@opt_combinations,
'skip-combinations' => \&collect_option, 'skip-combinations' => \&collect_option,
'experimental=s' => \$opt_experimental, 'experimental=s' => \@opt_experimentals,
'skip-im' => \&ignore_option, 'skip-im' => \&ignore_option,
# Specify ports # Specify ports
...@@ -1030,16 +1030,19 @@ sub command_line_setup { ...@@ -1030,16 +1030,19 @@ sub command_line_setup {
mtr_print_thick_line('#'); mtr_print_thick_line('#');
} }
if ( $opt_experimental ) if ( @opt_experimentals )
{ {
# $^O on Windows considered not generic enough # $^O on Windows considered not generic enough
my $plat= (IS_WINDOWS) ? 'windows' : $^O; my $plat= (IS_WINDOWS) ? 'windows' : $^O;
# read the list of experimental test cases from the file specified on # read the list of experimental test cases from the files specified on
# the command line # the command line
open(FILE, "<", $opt_experimental) or mtr_error("Can't read experimental file: $opt_experimental");
mtr_report("Using experimental file: $opt_experimental");
$experimental_test_cases = []; $experimental_test_cases = [];
foreach my $exp_file (@opt_experimentals)
{
open(FILE, "<", $exp_file)
or mtr_error("Can't read experimental file: $exp_file");
mtr_report("Using experimental file: $exp_file");
while(<FILE>) { while(<FILE>) {
chomp; chomp;
# remove comments (# foo) at the beginning of the line, or after a # remove comments (# foo) at the beginning of the line, or after a
...@@ -1068,6 +1071,7 @@ sub command_line_setup { ...@@ -1068,6 +1071,7 @@ sub command_line_setup {
} }
close FILE; close FILE;
} }
}
foreach my $arg ( @ARGV ) foreach my $arg ( @ARGV )
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment