]> git.ipfire.org Git - thirdparty/libcgroup.git/commitdiff
ftests: Add minimum Python version
authorKamalesh Babulal <kamalesh.babulal@oracle.com>
Sat, 8 Jun 2024 07:28:05 +0000 (12:58 +0530)
committerTom Hromatka <tom.hromatka@oracle.com>
Tue, 11 Jun 2024 15:03:15 +0000 (09:03 -0600)
Add Python version >= 3.6, as minimum required for executing ftests.
It's required for multi-process/multi-threaded test cases to execute
without time outs.

Signed-off-by: Kamalesh Babulal <kamalesh.babulal@oracle.com>
Signed-off-by: Tom Hromatka <tom.hromatka@oracle.com>
tests/ftests/ftests.py

index da26d5904ce1a0582a25dfac6d7c49c27bdd5ea6..51162c692cda67ba388f4d50462355faab937fbd 100755 (executable)
@@ -452,6 +452,10 @@ def main(config):
     AUTOMAKE_HARD_ERROR = 99
     AUTOMAKE_PASSED = 0
 
+    if not (sys.version_info.major == 3 and sys.version_info.minor >= 6):
+        print("Minimum Python 3.6 required")
+        return AUTOMAKE_HARD_ERROR
+
     try:
         setup(config, record_time=True)
         [passed_cnt, failed_cnt, skipped_cnt] = run_tests(config)