summaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
Diffstat (limited to 'shell')
-rw-r--r--shell/test/EXPRESSIONS6
-rw-r--r--shell/test/RULES5
2 files changed, 10 insertions, 1 deletions
diff --git a/shell/test/EXPRESSIONS b/shell/test/EXPRESSIONS
index d9b1fbc..3ab3605 100644
--- a/shell/test/EXPRESSIONS
+++ b/shell/test/EXPRESSIONS
@@ -1,6 +1,7 @@
{ "test-action":
{ "vars":
[ "TEST_ENV"
+ , "TIMEOUT_SCALE"
, "ATTEMPT"
, "name"
, "test.sh"
@@ -132,6 +133,8 @@
{ "type": "join"
, "$1": ["shell test ", {"type": "var", "name": "name"}, " failed"]
}
+ , "timeout scaling":
+ {"type": "var", "name": "TIMEOUT_SCALE", "default": 1.0}
}
, "else":
{ "type": "ACTION"
@@ -151,6 +154,8 @@
, ")"
]
}
+ , "timeout scaling":
+ {"type": "var", "name": "TIMEOUT_SCALE", "default": 1.0}
}
}
}
@@ -158,6 +163,7 @@
, "test-result":
{ "vars":
[ "TEST_ENV"
+ , "TIMEOUT_SCALE"
, "name"
, "test.sh"
, "keep"
diff --git a/shell/test/RULES b/shell/test/RULES
index 98bf27c..d6baa9c 100644
--- a/shell/test/RULES
+++ b/shell/test/RULES
@@ -2,7 +2,8 @@
{ "doc": ["Shell test, given by a test script"]
, "target_fields": ["deps", "test"]
, "string_fields": ["keep", "name"]
- , "config_vars": ["ARCH", "HOST_ARCH", "RUNS_PER_TEST", "TEST_ENV"]
+ , "config_vars":
+ ["ARCH", "HOST_ARCH", "RUNS_PER_TEST", "TEST_ENV", "TIMEOUT_SCALE"]
, "field_doc":
{ "test":
[ "The shell script for the test, launched with sh."
@@ -33,6 +34,8 @@
, "If set, no test action will be taken from cache."
]
, "TEST_ENV": ["The environment for executing the test runner."]
+ , "TIMEOUT_SCALE":
+ ["Factor on how to scale the timeout for this test. Defaults to 1.0."]
}
, "tainted": ["test"]
, "artifacts_doc":