diff options
Diffstat (limited to 'tests/specs/README.md')
-rw-r--r-- | tests/specs/README.md | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/tests/specs/README.md b/tests/specs/README.md index 5711b41d5..61fa60f53 100644 --- a/tests/specs/README.md +++ b/tests/specs/README.md @@ -28,7 +28,7 @@ cargo test test_name ## `__test__.json` file -This file describes the test to execute and the steps to execute. A basic +This file describes the test(s) to execute and the steps to execute. A basic example looks like: ```json @@ -57,6 +57,23 @@ Or another example that runs multiple steps: } ``` +Or if you want to run several tests at the same time: + +```json +{ + "tests": { + "ignore_dir": { + "args": "run script.ts", + "output": "script.out" + }, + "some_other_test": { + "args": "run other.ts", + "output": "other.out" + } + } +} +``` + ### Top level properties - `base` - The base config to use for the test. Options: @@ -71,13 +88,12 @@ Or another example that runs multiple steps: ### Step properties When writing a single step, these may be at the top level rather than nested in -a "steps" array. +a "steps" array or "tests" object. - `args` - A string (that will be spilt on whitespace into an args array) or an array of arguments. -- `output` - Path to use to assert the output. -- `cleanDenoDir` (boolean) - Whether to empty the deno_dir before running the - step. +- `output` - Path to use to assert the output or text (must end with an .out + extension) _or_ text to pattern match against the output. - `flaky` - Step should be repeated until success a maximum of 3 times. - `if` (`"windows"`, `"linux"`, `"mac"`, `"unix"`) - Whether to run this step. - `exitCode` (number) - Expected exit code. |