From 4138938b156a75fc5b6eae1b4b980eba4c875d87 Mon Sep 17 00:00:00 2001 From: Ilya Dryomov Date: Thu, 21 Jan 2021 12:15:34 +0100 Subject: [PATCH] qa: expand the documentation on the '$' suite feature Signed-off-by: Ilya Dryomov --- qa/README | 39 ++++++++++++++++++++++++++++++--------- 1 file changed, 30 insertions(+), 9 deletions(-) diff --git a/qa/README b/qa/README index 6b3ec220276..f9b8988c6f9 100644 --- a/qa/README +++ b/qa/README @@ -47,18 +47,39 @@ item), so this is really 2x2 = 4 tests, which are a + b2 + c + d1 a + b2 + c + d2 -A directory with a magic '$' file represents a test where one of the other -items is chosen randomly. For example, +A directory with a magic '$' file, or a directory whose name ends with '$', +represents a test where one of the non-magic items is chosen randomly. For +example, both -suites/foo/$ -suites/foo/a.yaml -suites/foo/b.yaml -suites/foo/c.yaml + suites/foo/$ + suites/foo/a.yaml + suites/foo/b.yaml + suites/foo/c.yaml -is a single test. It will be either a.yaml, b.yaml or c.yaml. This can be -used in conjunction with the '%' file in other directories to run a series of -tests without causing an unwanted increase in the total number of jobs run. +and + + suites/foo$/a.yaml + suites/foo$/b.yaml + suites/foo$/c.yaml + +is a single test, either a, b or c. This can be used in conjunction with the +'%' file in the same (see below) or other directories to run a series of tests +without causing an unwanted increase in the total number of jobs run. Symlinks are okay. +One particular use of symlinks is to combine '%' and the latter form of '$' +feature. Consider supported_distros directory containing fragments that define +os_type and os_version: + + supported_distros/% + supported_distros/centos.yaml + supported_distros/rhel.yaml + supported_distros/ubuntu.yaml + +A test that links supported_distros as distros (a name that doesn't end with +'$') will be run three times: on centos, rhel and ubuntu. A test that links +supported_distros as distros$ will be run just once: either on centos, rhel or +ubuntu, chosen randomly. + The teuthology code can be found in https://github.com/ceph/teuthology.git -- 2.39.5