summaryrefslogtreecommitdiff
path: root/tests/admin_scripts
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2025-10-30 12:38:17 +0100
committerGitHub <noreply@github.com>2025-10-30 08:38:17 -0300
commit3939cd279569fde44f557d79f20bb5b1a02440af (patch)
tree0d2f969314278a6feaadb186ffbf2542eae04f05 /tests/admin_scripts
parent7fc9db1c6a3a4865d85338f26812ce80f076ebec (diff)
Refs #36680 -- Fixed admin_scripts tests crash when black is not installed.
Regression in 6436ec321073bf0622af815e0af08f54c97f9b30.
Diffstat (limited to 'tests/admin_scripts')
-rw-r--r--tests/admin_scripts/tests.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/admin_scripts/tests.py b/tests/admin_scripts/tests.py
index 9442822bd6..c01a5571dc 100644
--- a/tests/admin_scripts/tests.py
+++ b/tests/admin_scripts/tests.py
@@ -119,7 +119,8 @@ class AdminScriptTestCase(SimpleTestCase):
path_component
for path_component in os.environ.get("PATH", "").split(os.pathsep)
for formatter_path in find_formatters().values()
- if os.path.commonpath([path_component, formatter_path]) == os.sep
+ if formatter_path
+ and os.path.commonpath([path_component, formatter_path]) == os.sep
]
)