testbot: Fix handling of tests for dll names containing dots or dashes.
Francois Gouget
fgouget at codeweavers.com
Thu Apr 18 12:24:43 CDT 2013
Conformance tests for 'dlls' containing dots in their name, 'winspool.drv' for instance, should be allowed.
Wine does not support conformance tests for dlls containing dashes in their names however, 'api-ms-*' for instance, so reject those.
---
This should fix:
* bug 33313 - NewTestBot: Can't submit tests for winspool.drv
http://bugs.winehq.org/show_bug.cgi?id=33313
Concerning dlls with dashes in their names, see:
* bug 33375 - Cannot test dlls with dashes in their name
http://bugs.winehq.org/show_bug.cgi?id=33375
testbot/bin/WineRunBuild.pl | 12 +++++++-----
testbot/web/Submit.pl | 4 ++--
2 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/testbot/bin/WineRunBuild.pl b/testbot/bin/WineRunBuild.pl
index c230316..98a9211 100755
--- a/testbot/bin/WineRunBuild.pl
+++ b/testbot/bin/WineRunBuild.pl
@@ -202,14 +202,16 @@ foreach my $OtherStep (@{$Job->Steps->GetItems()})
$Run64 = 1 if ($OtherStep->FileType eq "exe64");
my $OtherFileName = $OtherStep->FileName;
- if ($OtherFileName =~ m/^([\w_\-]+)(|\.exe)_test(|64)\.exe$/)
+ if ($OtherFileName =~ m/^([\w_.]+)_test(?:64)?\.exe$/)
{
- if (defined $BaseName and $BaseName ne $1)
+ my $OtherBaseName = $1;
+ $OtherBaseName =~ s/\.exe$//;
+ if (defined $BaseName and $BaseName ne $OtherBaseName)
{
- FatalError "$1 doesn't match previously found $BaseName\n",
+ FatalError "$OtherBaseName doesn't match previously found $BaseName\n",
$FullErrFileName, $Job, $Task;
}
- $BaseName = $1;
+ $BaseName = $OtherBaseName;
}
}
if (!defined $BaseName)
@@ -292,7 +294,7 @@ if ($NewStatus eq "completed")
next if ($OtherStep->No == $StepNo);
my $OtherFileName = $OtherStep->FileName;
- next if ($OtherFileName !~ /^[\w_\-]+(?:|\.exe)_test(?:|64)\.exe$/);
+ next if ($OtherFileName !~ /^[\w_.]+_test(?:64)?\.exe$/);
my $OtherStepDir = "$DataDir/jobs/$JobId/" . $OtherStep->No;
mkdir $OtherStepDir;
diff --git a/testbot/web/Submit.pl b/testbot/web/Submit.pl
index 42ca77a..f73ae6a 100644
--- a/testbot/web/Submit.pl
+++ b/testbot/web/Submit.pl
@@ -470,9 +470,9 @@ sub Validate
elsif ($self->{Page} == 3 && $self->GetParam("Page") == 3)
{
if (($self->GetParam("FileType") eq "patchdlls" &&
- ! ($self->GetParam("TestExecutable") =~ m/^[a-zA-Z0-9_]+_test\.exe/)) ||
+ ! ($self->GetParam("TestExecutable") =~ m/^[\w_.]+_test\.exe/)) ||
($self->GetParam("FileType") eq "patchprograms") &&
- ! ($self->GetParam("TestExecutable") =~ m/^[a-zA-Z0-9_]+\.exe_test\.exe/))
+ ! ($self->GetParam("TestExecutable") =~ m/^[\w_.]+\.exe_test\.exe/))
{
$self->{ErrMessage} = "Invalid name for Test executable";
$self->{ErrField} = "TestExecutable";
--
1.7.10.4
More information about the wine-patches
mailing list