mirror of
https://github.com/cedricbonhomme/Stegano.git
synced 2025-05-12 17:18:30 +02:00
Updated tests for lsbset.
This commit is contained in:
parent
031e1ca84c
commit
3279b0c52a
1 changed files with 7 additions and 0 deletions
|
@ -53,6 +53,13 @@ class TestLSBSet(unittest.TestCase):
|
|||
|
||||
self.assertEqual(message, clear_message)
|
||||
|
||||
def test_with_too_long_message(self):
|
||||
with open("./tests/sample-files/lorem_ipsum.txt") as f:
|
||||
message = f.read()
|
||||
with self.assertRaises(Exception):
|
||||
lsbset.hide("./tests/sample-files/Lenna.png", message,
|
||||
generators.eratosthenes())
|
||||
|
||||
def test_hide_and_reveal_with_bad_generator(self):
|
||||
message_to_hide = "Hello World!"
|
||||
secret = lsbset.hide("./tests/sample-files/Lenna.png", message_to_hide,
|
||||
|
|
Loading…
Add table
Reference in a new issue