aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Fu <vincent.fu@samsung.com>2023-07-31 17:02:55 +0000
committerVincent Fu <vincent.fu@samsung.com>2023-08-14 10:43:45 -0400
commit140a30e36eeb87b2e6cd037e622e119886db34d0 (patch)
tree675296fe75a9e96ba0efa232e159172f3a767c91
parent08371767da0ad33b7901f93682356ac46158c0f9 (diff)
downloadfio-140a30e36eeb87b2e6cd037e622e119886db34d0.tar.gz
t/fiotestlib: use config variable to skip test at runtime
Check a test config variable to skip a test at runtime. This will be used to skip a test when the test runner determines that it should not be run. Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
-rwxr-xr-xt/fiotestlib.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/t/fiotestlib.py b/t/fiotestlib.py
index 1f35de0ae..a96338a38 100755
--- a/t/fiotestlib.py
+++ b/t/fiotestlib.py
@@ -382,9 +382,10 @@ def run_fio_tests(test_list, test_env, args):
for config in test_list:
if (args.skip and config['test_id'] in args.skip) or \
- (args.run_only and config['test_id'] not in args.run_only):
+ (args.run_only and config['test_id'] not in args.run_only) or \
+ ('force_skip' in config and config['force_skip']):
skipped = skipped + 1
- print(f"Test {config['test_id']} SKIPPED (User request)")
+ print(f"Test {config['test_id']} SKIPPED (User request or override)")
continue
if issubclass(config['test_class'], FioJobFileTest):