summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorChristoph Reiter <reiter.christoph@gmail.com>2024-03-15 19:21:51 +0100
committerEli Schwartz <eschwartz93@gmail.com>2024-03-17 04:46:26 -0400
commit0762b86e59629d82c1e7efaeb5dc6c1381d5af1a (patch)
treee1cbd4ab02adf1bd80107b77b6bc590e9c65c265 /docs
parent05bbe45cc228c78c47f57c88a04acd937a60f8bb (diff)
downloadmeson-0762b86e59629d82c1e7efaeb5dc6c1381d5af1a.tar.gz
tests: rename skip_on_jobname to expect_skip_on_jobname and skip_on_os to expect_skip_on_os
The test.json format currently has three keys related to skipping tests: * `skip_on_jobname` * `skip_on_os` * `skip_on_env` While `skip_on_env` marks the test itself as skipped, i.e. they don't get run when the conditions are met, the other two skip options are just marking the test as "expected to be skipped" if the conditions apply, i.e. they want to see `MESON_SKIP_TEST` in the output and things will fail if that doesn't happen. They don't actually skip the tests as the names imply. To make this clearer rename the keys: * `skip_on_jobname` -> `expect_skip_on_jobname` * `skip_on_os` -> `expect_skip_on_os` `skip_on_env` stays the same, since that actually skips. The docs were also confused about this, so adjust that too.
Diffstat (limited to 'docs')
-rw-r--r--docs/markdown/Contributing.md22
1 files changed, 12 insertions, 10 deletions
diff --git a/docs/markdown/Contributing.md b/docs/markdown/Contributing.md
index 68e943bff..731abc87d 100644
--- a/docs/markdown/Contributing.md
+++ b/docs/markdown/Contributing.md
@@ -334,9 +334,11 @@ Each value must contain the `val` key for the value of the option.
`null` can be used for adding matrix entries without the current
option.
-The `skip_on_env`, `skip_on_jobname` and `skip_on_os` keys (as described below)
-may be used in the value to skip that matrix entry, based on the current
-environment.
+The `skip_on_env` key (as described below) may be used in the value to skip that
+matrix entry, based on the current environment.
+
+The `expect_skip_on_jobname` and `expect_skip_on_os` keys (as described below)
+may be used to expect that the test will be skipped, based on the current environment.
Similarly, the `compilers` key can be used to define a mapping of
compilers to languages that are required for this value.
@@ -412,23 +414,23 @@ The `skip_on_env` key can be used to specify a list of environment variables. If
at least one environment variable in the `skip_on_env` list is present, the test
is skipped.
-#### skip_on_jobname
+#### expect_skip_on_jobname
-The `skip_on_jobname` key contains a list of strings. If the `MESON_CI_JOBNAME`
+The `expect_skip_on_jobname` key contains a list of strings. If the `MESON_CI_JOBNAME`
environment variable is set, and any of them are a sub-string of it, the test is
expected to be skipped (that is, it is expected that the test will output
`MESON_SKIP_TEST`, because the CI environment is not one in which it can run,
for whatever reason).
-The test is failed if it skips or runs unexpectedly.
+The test is failed if it either skips unexpectedly or runs unexpectedly.
-#### skip_on_os
+#### expect_skip_on_os
-The `skip_on_os` key can be used to specify a list of OS names (or their
-negations, prefixed with a `!`). If at least one item in the `skip_on_os` list
+The `expect_skip_on_os` key can be used to specify a list of OS names (or their
+negations, prefixed with a `!`). If at least one item in the `expect_skip_on_os` list
is matched, the test is expected to be skipped.
-The test is failed if it skips or runs unexpectedly.
+The test is failed if it either skips unexpectedly or runs unexpectedly.
### Skipping integration tests