X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=t%2Fselenium%2FAllTests.t;h=c5ebf1d19e600b793e48c8d13ce05a2ff30c4527;hb=58a1b54b6a04d70fda952ca86bc3b85b866264e9;hp=8a1a13e39b81357791fcd86b22b9f3368fc4d3e8;hpb=c1efeacb2b7cad96dcd458f28e96e05029d150d6;p=kivitendo-erp.git diff --git a/t/selenium/AllTests.t b/t/selenium/AllTests.t index 8a1a13e39..c5ebf1d19 100644 --- a/t/selenium/AllTests.t +++ b/t/selenium/AllTests.t @@ -61,7 +61,7 @@ # plan tests => 200; # Need to be cutomized # } sub init_server { - our $singlefileonly = 0; + my $singlefileonly = 0; if ($_[0] eq "singlefileonly") { $singlefileonly = 1; shift; @@ -117,13 +117,21 @@ foreach my $scriptdir (@_) { opendir(SCRIPTS, 't/selenium/testscripts/' . $scriptdir) or die "Can't open directory!" . $!; foreach (sort readdir(SCRIPTS)) { - require_ok("t/selenium/testscripts/". $scriptdir . "/" . $_) if ( $_ =~ /^\w\d\d\d.*\.t$/); + if ( $_ =~ /^\w\d\d\d.*\.t$|^\d\d\d.*\.t$/ && !$sel->{ran_tests}{"t/selenium/testscripts/". $scriptdir . "/" . $_}) { + require_ok("t/selenium/testscripts/". $scriptdir . "/" . $_); + $sel->{ran_tests}{"t/selenium/testscripts/". $scriptdir . "/" . $_} = 1; + } } closedir(SCRIPTS); } } else { - foreach (@_) { require_ok($_); } + foreach (@_) { + if ( $_ =~ /^.*\/\w\d\d\d.*\.t$|^.*\/\d\d\d.*\.t$/ && !$sel->{ran_tests}{$_}) { + require_ok($_); + $sel->{ran_tests}{$_} = 1; + } + } } if($!) { @! = ("Test fehlgeschlagen!");