Unverified Commit ab59dc01 authored by boklm's avatar boklm
Browse files

tbb-testsuite: allow testing more than one bundle

parent c7440b33
...@@ -17,9 +17,10 @@ sub exit_error { ...@@ -17,9 +17,10 @@ sub exit_error {
} }
sub get_options { sub get_options {
my @options = qw(os=s tbbfile=s language=s); my @options = qw(os=s language=s);
my %res = %default_options; my %res = %default_options;
Getopt::Long::GetOptionsFromArray(\@_, \%res, @options) || exit 1; Getopt::Long::GetOptionsFromArray(\@_, \%res, @options) || exit 1;
$res{files} = \@_;
return \%res; return \%res;
} }
...@@ -66,11 +67,18 @@ sub selenium_tests { ...@@ -66,11 +67,18 @@ sub selenium_tests {
} }
} }
$options->{basedir} = getcwd; sub test_tbb {
$options->{tbbdir} = extract_tbb($options->{tbbfile}); my ($tbbfile) = @_;
chdir $options->{tbbdir} || exit_error "Can't enter directory $options->{tbbdir}"; my $oldcwd = getcwd;
setup_tbb; $options->{tbbdir} = extract_tbb($tbbfile);
print "tbbdir: $options->{tbbdir}\n"; chdir $options->{tbbdir} || exit_error "Can't enter directory $options->{tbbdir}";
mozmill_tests; setup_tbb;
selenium_tests; print "tbbdir: $options->{tbbdir}\n";
mozmill_tests;
selenium_tests;
chdir $oldcwd;
}
foreach my $tbbfile (@{$options->{files}}) {
test_tbb($tbbfile);
}
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