From b4e8115ec719e8852ccef852b7a8a06ec34b81db Mon Sep 17 00:00:00 2001 From: Tomasz Kramkowski Date: Mon, 27 Mar 2023 18:53:19 +0100 Subject: paste.db: readd missing import of sha256 --- tests/test_db.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests') diff --git a/tests/test_db.py b/tests/test_db.py index d1b269a..5c973ab 100644 --- a/tests/test_db.py +++ b/tests/test_db.py @@ -51,3 +51,9 @@ def test_hash_behaves_normally(unmigrated_conn, a, b, expected): "SELECT DATA_HASH(?) == DATA_HASH(?)", (a, b) ).fetchone() assert res == (1 if expected else 0) + + +@pytest.mark.parametrize("a,b,expected", hash_testdata) +def test_sha256_behaves_normally(unmigrated_conn, a, b, expected): + (res,) = unmigrated_conn.execute("SELECT SHA256(?) == SHA256(?)", (a, b)).fetchone() + assert res == (1 if expected else 0) -- cgit v1.2.3-54-g00ecf