From c58b33b4e0940f3ec89d6e302a0c90e2ec1f1fbc Mon Sep 17 00:00:00 2001 From: Vincent Fu Date: Thu, 12 Dec 2019 15:31:14 -0700 Subject: [PATCH] t/run-fio-tests: automatically skip t/jobs/t0005 on Windows t0005 uses direct IO with a sync ioengine which is not supported under Windows. Automatically skip this test when run-fio-tests is run under Windows. With this change we no longer need to skip test 5 in the appveyor setup. Signed-off-by: Vincent Fu --- .appveyor.yml | 2 +- t/run-fio-tests.py | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index 4fb0a90d..bf0978ad 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -25,7 +25,7 @@ after_build: test_script: - 'bash.exe -lc "cd \"${APPVEYOR_BUILD_FOLDER}\" && file.exe fio.exe && make.exe test' - - 'bash.exe -lc "cd \"${APPVEYOR_BUILD_FOLDER}\" && python.exe t/run-fio-tests.py --skip 5 --debug' + - 'bash.exe -lc "cd \"${APPVEYOR_BUILD_FOLDER}\" && python.exe t/run-fio-tests.py --debug' artifacts: - path: os\windows\*.msi diff --git a/t/run-fio-tests.py b/t/run-fio-tests.py index a0a1e8fa..3d236e37 100755 --- a/t/run-fio-tests.py +++ b/t/run-fio-tests.py @@ -428,11 +428,13 @@ class Requirements(object): _root = False _zoned_nullb = False _not_macos = False + _not_windows = False _unittests = False _cpucount4 = False def __init__(self, fio_root): Requirements._not_macos = platform.system() != "Darwin" + Requirements._not_windows = platform.system() != "Windows" Requirements._linux = platform.system() == "Linux" if Requirements._linux: @@ -470,6 +472,7 @@ class Requirements(object): Requirements.root, Requirements.zoned_nullb, Requirements.not_macos, + Requirements.not_windows, Requirements.unittests, Requirements.cpucount4] for req in req_list: @@ -494,6 +497,9 @@ class Requirements(object): def not_macos(): return Requirements._not_macos, "platform other than macOS required" + def not_windows(): + return Requirements._not_windows, "platform other than Windows required" + def unittests(): return Requirements._unittests, "Unittests support required" @@ -561,7 +567,7 @@ TEST_LIST = [ 'pre_job': None, 'pre_success': None, 'output_format': 'json', - 'requirements': [], + 'requirements': [Requirements.not_windows], }, { 'test_id': 6, -- 2.25.1