Skip to content

Commit

Permalink
Fix backend tests for huffman_balance
Browse files Browse the repository at this point in the history
  • Loading branch information
dimkarakostas committed Dec 15, 2017
1 parent 9b99116 commit 5060ce1
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions backend/breach/tests/test_strategy.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ def test_same_round_different_batch(self, Sniffer):
amount=1,
knownsecret='testsecret',
knownalphabet='01',
huffman_balance=False
)
self.dif_batch_samplesets = [
SampleSet.objects.create(
Expand Down Expand Up @@ -116,7 +117,8 @@ def test_advance_round(self, Sniffer):
endpoint='https://di.uoa.gr/?breach=%s',
prefix='test',
alphabet='0123456789',
name='ruptureit'
name='ruptureit',
huffman_balance=False
)

next_round_victim = Victim.objects.create(
Expand All @@ -130,6 +132,7 @@ def test_advance_round(self, Sniffer):
amount=1,
knownsecret='testsecret',
knownalphabet='01',
huffman_balance=False
)

SampleSet.objects.create(
Expand Down Expand Up @@ -192,7 +195,8 @@ def test_divide_and_conquer(self, Sniffer):
prefix='test',
alphabet='0123',
name='webuoa',
method=DIVIDE_CONQUER
method=DIVIDE_CONQUER,
huffman_balance=False
)

victim = self.create_mock_victim(mock_target)
Expand Down Expand Up @@ -221,7 +225,8 @@ def test_downgrade_to_serial(self, Sniffer):
prefix='test',
alphabet='0123',
maxreflectionlength=16,
method=2
method=2,
huffman_balance=False
)

victim = Victim.objects.create(
Expand All @@ -244,7 +249,8 @@ def test_downgrade_huffman(self, Sniffer):
prefix='test',
alphabet='0123',
maxreflectionlength=12,
method=2
method=2,
huffman_balance=False
)

victim = Victim.objects.create(
Expand All @@ -267,7 +273,8 @@ def test_maxreflectionerror(self, Sniffer):
prefix='test',
alphabet='0123',
maxreflectionlength=6,
method=2
method=2,
huffman_balance=False
)

victim = Victim.objects.create(
Expand Down

0 comments on commit 5060ce1

Please # to comment.