Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
pcriadoperez committed Dec 11, 2024
1 parent 25fb6b1 commit 2e27c2a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ def test_round_step_size_precision():
def test_round_step_size_always_rounds_down():
"""Test that values are always rounded down"""
assert round_step_size(1.19, 0.1) == 1.1
assert round_step_size(1.99, 1.0) == 1.0
assert round_step_size(1.99, 1.0) == 1.9
assert round_step_size(0.99999, 0.1) == 0.9


def test_round_step_size_invalid_inputs():
"""Test error handling for invalid inputs"""
with pytest.raises(TypeError):
with pytest.raises(InvalidOperation):
round_step_size(None, 0.1) # type: ignore

with pytest.raises((ValueError, InvalidOperation)):
Expand Down

0 comments on commit 2e27c2a

Please sign in to comment.