]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
run-unit-tests: apply "ruff format"
authorYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 19 Feb 2026 17:00:21 +0000 (02:00 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 17 May 2026 17:44:46 +0000 (02:44 +0900)
test/run-unit-tests.py

index de8ac5c26cb43725f040d6b9cdf61bd58ebe459b..1b790d7a5cf47ae880f109c9b7d3d6053ed774ff 100755 (executable)
@@ -6,8 +6,10 @@ import os
 import pathlib
 import subprocess
 import sys
+
 try:
     import colorama as c
+
     GREEN = c.Fore.GREEN
     YELLOW = c.Fore.YELLOW
     RED = c.Fore.RED
@@ -16,23 +18,38 @@ try:
 except ImportError:
     GREEN = YELLOW = RED = RESET_ALL = BRIGHT = ''
 
+
 class total:
     total = None
     good = 0
     skip = 0
     fail = 0
 
+
 def argument_parser():
     p = argparse.ArgumentParser()
-    p.add_argument('-u', '--unsafe', action='store_true',
-                   help='run "unsafe" tests too')
-    p.add_argument('-A', '--artifact_directory',
-                   help='store output from failed tests in this dir')
-    p.add_argument('-s', '--skip', action='append', default=[],
-                   help='skip the named test')
+    p.add_argument(
+        '-u',
+        '--unsafe',
+        action='store_true',
+        help='run "unsafe" tests too',
+    )
+    p.add_argument(
+        '-A',
+        '--artifact_directory',
+        help='store output from failed tests in this dir',
+    )
+    p.add_argument(
+        '-s',
+        '--skip',
+        action='append',
+        default=[],
+        help='skip the named test',
+    )
 
     return p
 
+
 opts = argument_parser().parse_args()
 
 unittestdir = pathlib.Path(__file__).parent.absolute() / 'unit-tests'