aboutsummaryrefslogtreecommitdiffstats
path: root/csource/csource_test.go
diff options
context:
space:
mode:
authorAndrey Konovalov <andreyknvl@google.com>2017-05-18 14:26:02 +0200
committerAndrey Konovalov <andreyknvl@google.com>2017-06-12 19:48:23 +0200
commit5597911fbf26237b9d11a0f6293e4b52b2d9069c (patch)
tree9559a1e14daff7759f4ba6ef6740c6809567d081 /csource/csource_test.go
parente7366c123e8e62cab5e70998b56e832c77178a59 (diff)
csource: use tmp dir only when necessary
Diffstat (limited to 'csource/csource_test.go')
-rw-r--r--csource/csource_test.go24
1 files changed, 13 insertions, 11 deletions
diff --git a/csource/csource_test.go b/csource/csource_test.go
index 8ca7bb5ce..3e09a3019 100644
--- a/csource/csource_test.go
+++ b/csource/csource_test.go
@@ -35,18 +35,20 @@ func allOptionsPermutations() []Options {
for _, opt.Procs = range []int{1, 4} {
for _, opt.Sandbox = range []string{"none", "setuid", "namespace"} {
for _, opt.Repro = range []bool{false, true} {
- for _, opt.EnableTun = range []bool{false, true} {
- for _, opt.Fault = range []bool{false, true} {
- if opt.Collide && !opt.Threaded {
- continue
+ for _, opt.Fault = range []bool{false, true} {
+ for _, opt.EnableTun = range []bool{false, true} {
+ for _, opt.UseTmpDir = range []bool{false, true} {
+ if opt.Collide && !opt.Threaded {
+ continue
+ }
+ if !opt.Repeat && opt.Procs != 1 {
+ continue
+ }
+ if testing.Short() && opt.Procs != 1 {
+ continue
+ }
+ options = append(options, opt)
}
- if !opt.Repeat && opt.Procs != 1 {
- continue
- }
- if testing.Short() && opt.Procs != 1 {
- continue
- }
- options = append(options, opt)
}
}
}