Skip to content
Prev Previous commit
Next Next commit
tests: remove irrelevant whitespace from strings before comparing
  • Loading branch information
dabeycorn committed Oct 19, 2025
commit 65ed969a61c0242b299f42a523c631dc4658a68d
5 changes: 5 additions & 0 deletions tests/test_distanceprinter.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,9 @@ def test_distanceprinter(monkeypatch):
# Remove stru file path when comparing as it may differ between machines
resultstr = resultstr.split("\n", 2)[2]
teststr = teststr.split("\n", 2)[2]

# Remove irrelevant whitespace when comparing
resultstr = "".join(resultstr.split())
teststr = "".join(teststr.split())

assert resultstr == teststr
Loading