Running a subset of tests

Filtering by Tag

Tests can have one or more tags by setting the tags property. This can be either a string or an array of strings.

$ cat spec.toml
[[http]]
url = 'http://example.com/ping-internal-networks.cfm'
status = 200
timeout = 60
tags = [ 'slow' ]

To only run tests that match a certain tag, pass the --tags or -t command-line option. For example, to only run slow checks, use --tags slow:

$ specsheet spec.toml --tags=slow
1 test run

You can also run all tests that do not match a certain tag by passing the --skip-tags command-line option:

$ specsheet spec.toml --skip-tags=slow
0 tests run

Filtering by Type

Use the --types or -T command-line option to only run tests with the given test type. For example, to only run HTTP tests, use --types http:

$ specsheet spec.toml --types=http
1 test run

To do the opposite and skip tests of a certain type, use --skip-types:

$ specsheet spec.toml --skip-types=http
0 tests run