aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/system/dispatcher_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/system/dispatcher_test.go')
-rw-r--r--internal/system/dispatcher_test.go15
1 files changed, 12 insertions, 3 deletions
diff --git a/internal/system/dispatcher_test.go b/internal/system/dispatcher_test.go
index 85bd45bf..ed162171 100644
--- a/internal/system/dispatcher_test.go
+++ b/internal/system/dispatcher_test.go
@@ -36,17 +36,26 @@ type opBehaviourTestCase struct {
wantErrRevert error
}
-func checkOpBehaviour(t *testing.T, testCases []opBehaviourTestCase) {
+const (
+ // checkNoParallel causes checkOpBehaviour to skip setting tests as parallel.
+ checkNoParallel = 1 << iota
+)
+
+func checkOpBehaviour(t *testing.T, flags int, testCases []opBehaviourTestCase) {
t.Helper()
t.Run("behaviour", func(t *testing.T) {
t.Helper()
- t.Parallel()
+ if flags&checkNoParallel == 0 {
+ t.Parallel()
+ }
for _, tc := range testCases {
t.Run(tc.name, func(t *testing.T) {
t.Helper()
- t.Parallel()
+ if flags&checkNoParallel == 0 {
+ t.Parallel()
+ }
var ec *Criteria
if tc.ec != 0xff {