Skip to content

Commit 7916fda

Browse files
committed
Testing a snapshot testing library is so hard!
1 parent 470eff4 commit 7916fda

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

python/example-pytest-selfie/tests/binary_test.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,8 @@ def test_base64_mismatch():
5252
expect_selfie(b"test data").to_be_base64("AAAA")
5353
expect_selfie(
5454
safify(str(exc_info.value))
55-
).to_be("""Snapshot mismatch, TODO: string comparison
56-
- update this snapshot by adding `_TODO` to the function name
57-
- update all snapshots in this file by adding `#safewordonce` or `#safewordWRITE`""")
55+
).to_be("Snapshot mismatch, TODO: string comparison")
5856

5957
def safify(string: str) -> str:
60-
return string.replace("selfie", "safeword").replace("SELFIE", "safeword")
58+
return string.split("\n")[0]
6159

0 commit comments

Comments
 (0)