Skip to content

Commit bca8f8e

Browse files
committed
style: format test_ml_environment_manager.py
🤖 Generated with [Claude Code](https://claude.com/claude-code)
1 parent 027cbb5 commit bca8f8e

File tree

1 file changed

+22
-4
lines changed

1 file changed

+22
-4
lines changed

tests/unit/core/test_ml_environment_manager.py

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,17 @@ def test_production_environment_detection(self):
5959
"""Test production environment with full ML capabilities."""
6060
# Clear UCKN_DISABLE_TORCH and CI variables to allow production detection
6161
# Use clear=True to remove CI, GITHUB_ACTIONS, etc.
62-
minimal_env = {k: v for k, v in os.environ.items()
63-
if k not in ("CI", "GITHUB_ACTIONS", "CONTINUOUS_INTEGRATION", "UCKN_DISABLE_TORCH")}
62+
minimal_env = {
63+
k: v
64+
for k, v in os.environ.items()
65+
if k
66+
not in (
67+
"CI",
68+
"GITHUB_ACTIONS",
69+
"CONTINUOUS_INTEGRATION",
70+
"UCKN_DISABLE_TORCH",
71+
)
72+
}
6473
minimal_env["UCKN_DISABLE_TORCH"] = "0"
6574
with patch.dict(os.environ, minimal_env, clear=True):
6675
# Mock all ML packages as available
@@ -91,8 +100,17 @@ def mock_import(module_name):
91100
return module_name in ["sentence_transformers"]
92101

93102
# Clear UCKN_DISABLE_TORCH and CI variables to allow development detection
94-
minimal_env = {k: v for k, v in os.environ.items()
95-
if k not in ("CI", "GITHUB_ACTIONS", "CONTINUOUS_INTEGRATION", "UCKN_DISABLE_TORCH")}
103+
minimal_env = {
104+
k: v
105+
for k, v in os.environ.items()
106+
if k
107+
not in (
108+
"CI",
109+
"GITHUB_ACTIONS",
110+
"CONTINUOUS_INTEGRATION",
111+
"UCKN_DISABLE_TORCH",
112+
)
113+
}
96114
minimal_env["UCKN_DISABLE_TORCH"] = "0"
97115
with patch.dict(os.environ, minimal_env, clear=True):
98116
with patch.object(

0 commit comments

Comments
 (0)