Skip to content

Commit

Permalink
test: remove unsupported f-string format
Browse files Browse the repository at this point in the history
  • Loading branch information
skim0119 committed Jul 11, 2022
1 parent 38f6693 commit 9009fa6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion elastica/callback_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,9 @@ def __init__(
# Assertions
MIN_STEP_SKIP = 100
if step_skip <= MIN_STEP_SKIP:
logging.warning(f"We recommend ({step_skip=}) at least {MIN_STEP_SKIP}")
logging.warning(
f"We recommend (step_skip={step_skip}) at least {MIN_STEP_SKIP}"
)
assert (
method in ExportCallBack.AVAILABLE_METHOD
), f"The exporting method ({method}) is not supported. Please use one of {ExportCallBack.AVAILABLE_METHOD}."
Expand Down
2 changes: 1 addition & 1 deletion tests/test_callback_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def test_export_call_back_small_stepsize_warning(self, caplog, step_skip):
assert record_tuple[0] == "root"
assert record_tuple[1] == logging.WARNING
assert str(100) in record_tuple[2]
assert f"recommend ({step_skip=}) at least" in record_tuple[2]
assert f"recommend (step_skip={step_skip}) at least" in record_tuple[2]

def test_export_call_back_file_recreate_warning(self, caplog):
mock_rod = MockRodWithElements(5)
Expand Down

0 comments on commit 9009fa6

Please sign in to comment.