mirror of
https://github.com/cedricbonhomme/Stegano.git
synced 2025-06-28 11:16:14 +02:00
added: test cases for shi-tomashi generator
Signed-off-by: thundersparkf <devagastya0@gmail.com>
This commit is contained in:
parent
8ea1553538
commit
c774e9e91c
3 changed files with 1049 additions and 0 deletions
|
@ -68,6 +68,18 @@ class TestLSBSet(unittest.TestCase):
|
|||
|
||||
self.assertEqual(message, clear_message)
|
||||
|
||||
def test_hide_and_reveal_with_shi_tomashi(self):
|
||||
messages_to_hide = ["foo bar"]
|
||||
for message in messages_to_hide:
|
||||
secret = lsbset.hide(
|
||||
"./tests/sample-files/Lenna.png", message, generators.shi_tomashi("./tests/sample-files/Lenna.png")
|
||||
)
|
||||
secret.save("./image.png")
|
||||
|
||||
clear_message = lsbset.reveal("./image.png", generators.shi_tomashi("./tests/sample-files/Lenna.png"))
|
||||
|
||||
self.assertEqual(message, clear_message)
|
||||
|
||||
def test_hide_and_reveal_with_shift(self):
|
||||
messages_to_hide = ["a", "foo", "Hello World!", ":Python:"]
|
||||
for message in messages_to_hide:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue