summaryrefslogtreecommitdiff
path: root/selftest
diff options
context:
space:
mode:
Diffstat (limited to 'selftest')
-rwxr-xr-xselftest/selftest.pl9
-rw-r--r--selftest/target/Samba.pm4
-rwxr-xr-xselftest/target/Samba3.pm2
-rw-r--r--selftest/target/Samba4.pm2
4 files changed, 12 insertions, 5 deletions
diff --git a/selftest/selftest.pl b/selftest/selftest.pl
index e5ccbd8f37..462517271b 100755
--- a/selftest/selftest.pl
+++ b/selftest/selftest.pl
@@ -882,7 +882,9 @@ sub setup_env($$)
}
} else {
$testenv_vars = $target->setup_env($envname, $prefix);
- if (defined($testenv_vars) && not defined($testenv_vars->{target})) {
+ if (defined($testenv_vars) and $testenv_vars eq "UNKNOWN") {
+ return $testenv_vars;
+ } elsif (defined($testenv_vars) && not defined($testenv_vars->{target})) {
$testenv_vars->{target} = $target;
}
if (not defined($testenv_vars)) {
@@ -1024,6 +1026,11 @@ $envvarstr
Subunit::end_testsuite($name, "error",
"unable to set up environment $envname - exiting");
next;
+ } elsif ($envvars eq "UNKNOWN") {
+ Subunit::start_testsuite($name);
+ Subunit::end_testsuite($name, "skip",
+ "environment $envname is unknown in this test backend - skipping");
+ next;
}
# Generate a file with the individual tests to run, if the
diff --git a/selftest/target/Samba.pm b/selftest/target/Samba.pm
index 64bc405137..eea1987a4a 100644
--- a/selftest/target/Samba.pm
+++ b/selftest/target/Samba.pm
@@ -27,13 +27,13 @@ sub setup_env($$$)
$ENV{ENVNAME} = $envname;
my $env = $self->{samba4}->setup_env($envname, $path);
- if (defined($env)) {
+ if (defined($env) and $env ne "UNKNOWN") {
if (not defined($env->{target})) {
$env->{target} = $self->{samba4};
}
} else {
$env = $self->{samba3}->setup_env($envname, $path);
- if (defined($env)) {
+ if (defined($env) and $env ne "UNKNOWN") {
if (not defined($env->{target})) {
$env->{target} = $self->{samba3};
}
diff --git a/selftest/target/Samba3.pm b/selftest/target/Samba3.pm
index b710d5466d..7ecb481a46 100755
--- a/selftest/target/Samba3.pm
+++ b/selftest/target/Samba3.pm
@@ -112,7 +112,7 @@ sub setup_env($$$)
}
return $self->setup_member("$path/member", $self->{vars}->{s3dc});
} else {
- return undef;
+ return "UNKNOWN";
}
}
diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm
index 52c6d680d7..8ac3ee7eaf 100644
--- a/selftest/target/Samba4.pm
+++ b/selftest/target/Samba4.pm
@@ -1429,7 +1429,7 @@ sub setup_env($$$)
} elsif ($envname eq "plugin_s4_dc") {
return $self->setup_plugin_s4_dc("$path/plugin_s4_dc");
} else {
- return undef;
+ return "UNKNOWN";
}
}