Skip to content

Commit

Permalink
Make test work with old and new Python
Browse files Browse the repository at this point in the history
  • Loading branch information
HeMan committed Oct 16, 2024
1 parent cf5559d commit 040ad23
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Empty file added tests/__init__.py
Empty file.
4 changes: 2 additions & 2 deletions tests/test_binmap.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,11 @@ def test_value_bounds(self):
t = Temp()
with pytest.raises(struct.error) as excinfo:
t.temp = 256
assert "ubyte format requires 0 <= number <= 255" in str(excinfo)
assert "format requires 0 <= number <= 255" in str(excinfo)

with pytest.raises(struct.error) as excinfo:
t.temp = -1
assert "ubyte format requires 0 <= number <= 255" in str(excinfo)
assert "format requires 0 <= number <= 255" in str(excinfo)

def test_compare_equal(self):
t1 = Temp(temp=10)
Expand Down

0 comments on commit 040ad23

Please sign in to comment.