From 20878f264711caa8ca3ad68c2ce57e2f91a9c508 Mon Sep 17 00:00:00 2001 From: Cody Logan Date: Wed, 2 Sep 2020 16:03:48 -0700 Subject: Fix a testing error in Python 3.5 --- test/test_validations.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'test/test_validations.py') diff --git a/test/test_validations.py b/test/test_validations.py index aecee50..f2d2611 100644 --- a/test/test_validations.py +++ b/test/test_validations.py @@ -88,4 +88,6 @@ def test_verify_hash(tmp_path): tmp_file = tmp_path / file_name tmp_file.write_text(file_contents) - assert verify_hash(tmp_file) == file_sha1 + # Convert tmp_file from PosixPath to string so this test works with + # Python 3.5 (see https://stackoverflow.com/a/42694113). + assert verify_hash(str(tmp_file)) == file_sha1 -- cgit v1.2.3