Skip to content

Commit ba1565f

Browse files
author
benoit-cty
committed
run precommit
1 parent 241e498 commit ba1565f

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

tests/test_gpu_amd.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,9 @@ def _patched_import(name, *args, **kwargs):
433433
def test_oserror_sets_amdsmi_unavailable(self):
434434
"""OSError during amdsmi import (e.g. missing libamd_smi.so) must disable AMD GPU support."""
435435
module = self._import_gpu_amd_with_amdsmi_error(
436-
OSError("libamd_smi.so: cannot open shared object file: No such file or directory")
436+
OSError(
437+
"libamd_smi.so: cannot open shared object file: No such file or directory"
438+
)
437439
)
438440
assert module.amdsmi is None
439441
assert module.AMDSMI_AVAILABLE is False
@@ -459,7 +461,9 @@ def test_import_failure_logs_warning(self):
459461
KeyError("rocm_key"),
460462
AttributeError("missing attr"),
461463
):
462-
with mock.patch("codecarbon.external.logger.logger.warning") as warning_mock:
464+
with mock.patch(
465+
"codecarbon.external.logger.logger.warning"
466+
) as warning_mock:
463467
self._import_gpu_amd_with_amdsmi_error(error)
464468
warning_mock.assert_called()
465469

0 commit comments

Comments
 (0)