From 4c2f87887068fb6a34e6ec5a28aa384b9fcd5ddf Mon Sep 17 00:00:00 2001 From: ttgump Date: Sat, 14 Sep 2013 15:46:25 -0400 Subject: [PATCH] util_test_tools.init_repo parameter fix --- tests/integration/test_indefinite_freeze_attack.py | 2 +- tests/integration/test_mix_and_match_attack.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/integration/test_indefinite_freeze_attack.py b/tests/integration/test_indefinite_freeze_attack.py index 2b88e00c..bb1a4a8c 100755 --- a/tests/integration/test_indefinite_freeze_attack.py +++ b/tests/integration/test_indefinite_freeze_attack.py @@ -88,7 +88,7 @@ def test_indefinite_freeze_attack(TUF=False): try: # Setup. - root_repo, url, server_proc, keyids = util_test_tools.init_repo(tuf=TUF) + root_repo, url, server_proc, keyids = util_test_tools.init_repo(using_tuf=TUF) reg_repo = os.path.join(root_repo, 'reg_repo') tuf_repo = os.path.join(root_repo, 'tuf_repo') metadata_dir = os.path.join(tuf_repo, 'metadata') diff --git a/tests/integration/test_mix_and_match_attack.py b/tests/integration/test_mix_and_match_attack.py index da7d1dfa..5bf98db9 100755 --- a/tests/integration/test_mix_and_match_attack.py +++ b/tests/integration/test_mix_and_match_attack.py @@ -81,7 +81,7 @@ def test_mix_and_match_attack(TUF=False): try: # Setup / Stage 1 # --------------- - root_repo, url, server_proc, keyids = util_test_tools.init_repo(tuf=TUF) + root_repo, url, server_proc, keyids = util_test_tools.init_repo(using_tuf=TUF) reg_repo = os.path.join(root_repo, 'reg_repo') downloads = os.path.join(root_repo, 'downloads') evil_dir = tempfile.mkdtemp(dir=root_repo) @@ -166,8 +166,8 @@ def test_mix_and_match_attack(TUF=False): _download(url=url_to_file, filename=downloaded_file, using_tuf=TUF) except tuf.NoWorkingMirrorError as errors: for mirror_url, mirror_error in errors.mirror_errors.iteritems(): - if type(mirror_error) == tuf.BadHashError: - print 'Catched a Bad Hash Error!' + if type(mirror_error) == tuf.BadHashError: + print 'Catched a Bad Hash Error!' # Check whether the attack succeeded by inspecting the content of the # update. The update should contain 'Test NOT A'.