From ac6d87e83f91ed61b160e7cdd968f4a6f3d68f34 Mon Sep 17 00:00:00 2001 From: Victor Shyba Date: Thu, 16 Feb 2017 17:18:06 -0300 Subject: [style] add deprecation warning on legacy decoder --- testing/tests/client/test_crypto.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'testing') diff --git a/testing/tests/client/test_crypto.py b/testing/tests/client/test_crypto.py index 2d4d827b..399fdc99 100644 --- a/testing/tests/client/test_crypto.py +++ b/testing/tests/client/test_crypto.py @@ -292,6 +292,9 @@ class PreambleTestCase(unittest.TestCase): self.doc_info, BytesIO(ciphertext), secret='A' * 96).decrypt() assert cleartext == self.cleartext.getvalue() + warnings = self.flushWarnings() + assert len(warnings) == 1 + assert 'legacy document without size' in warnings[0]['message'] def _aes_encrypt(key, iv, data, aead=''): -- cgit v1.2.3