Skip to content

Commit

Permalink
black: format code with black version 24.1
Browse files Browse the repository at this point in the history
Adding skip fmt to avoid issues with black < 24.

New rule added in black 24 is:
> If an assignment statement is too long, we now prefer splitting on the right-hand side
> psf/black#3368
  • Loading branch information
rgonzalezfluendo authored and mdimopoulos committed Feb 15, 2024
1 parent d9106f5 commit 706865e
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions fluster/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ def __init__(

def _test(self) -> None:
if self.skip:
self.test_suite.test_vectors[
self.test_vector.name
].test_result = TestVectorResult.NOT_RUN
self.test_suite.test_vectors[self.test_vector.name].test_result = (
TestVectorResult.NOT_RUN
) # fmt: skip

return

Expand Down Expand Up @@ -89,17 +89,17 @@ def _test(self) -> None:
perf_counter() - start
)
except TimeoutExpired:
self.test_suite.test_vectors[
self.test_vector.name
].test_result = TestVectorResult.TIMEOUT
self.test_suite.test_vectors[self.test_vector.name].test_result = (
TestVectorResult.TIMEOUT
) # fmt: skip
self.test_suite.test_vectors[self.test_vector.name].test_time = (
perf_counter() - start
)
raise
except Exception:
self.test_suite.test_vectors[
self.test_vector.name
].test_result = TestVectorResult.ERROR
self.test_suite.test_vectors[self.test_vector.name].test_result = (
TestVectorResult.ERROR
) # fmt: skip
self.test_suite.test_vectors[self.test_vector.name].test_time = (
perf_counter() - start
)
Expand All @@ -113,20 +113,20 @@ def _test(self) -> None:
os.remove(output_filepath)

if not self.reference:
self.test_suite.test_vectors[
self.test_vector.name
].test_result = TestVectorResult.FAIL
self.test_suite.test_vectors[self.test_vector.name].test_result = (
TestVectorResult.FAIL
) # fmt: skip
if self.test_vector.result.lower() == result.lower():
self.test_suite.test_vectors[
self.test_vector.name
].test_result = TestVectorResult.SUCCESS
self.test_suite.test_vectors[self.test_vector.name].test_result = (
TestVectorResult.SUCCESS
) # fmt: skip
self.assertEqual(
self.test_vector.result.lower(),
result.lower(),
self.test_vector.name,
)
else:
self.test_suite.test_vectors[
self.test_vector.name
].test_result = TestVectorResult.REFERENCE
self.test_suite.test_vectors[self.test_vector.name].test_result = (
TestVectorResult.REFERENCE
) # fmt: skip
self.test_suite.test_vectors[self.test_vector.name].result = result

0 comments on commit 706865e

Please sign in to comment.