From 832dba2e1cd4e6e6ff9e8ea7afa98eebb44595e5 Mon Sep 17 00:00:00 2001 From: Magnus Ahltorp Date: Wed, 28 Jan 2015 13:42:06 +0100 Subject: Move hardcoded merge parameters to command line --- tools/testcase1.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'tools/testcase1.py') diff --git a/tools/testcase1.py b/tools/testcase1.py index 639cd69..415d475 100755 --- a/tools/testcase1.py +++ b/tools/testcase1.py @@ -120,16 +120,19 @@ def get_and_check_entry(timestamp, chain, leaf_index): len(submittedcertchain), len(submittedcertchain)) +def merge(): + return subprocess.call(["./merge.py", "--baseurl", "https://127.0.0.1:8080/", "--frontend", "https://127.0.0.1:8082/", "--storage", "https://127.0.0.1:8081/", "--mergedb", "../rel/mergedb", "--keyfile", "../rel/test/eckey.pem"]) + print_and_check_tree_size(0) -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) testgroup("cert1") result1 = do_add_chain(cc1) -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) print_and_check_tree_size(1) @@ -138,7 +141,7 @@ result2 = do_add_chain(cc1) assert_equal(result2["timestamp"], result1["timestamp"], "timestamp") -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) print_and_check_tree_size(1) @@ -152,7 +155,7 @@ testgroup("cert2") result3 = do_add_chain(cc2) -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) print_and_check_tree_size(2) @@ -164,7 +167,7 @@ testgroup("cert3") result4 = do_add_chain(cc3) -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) print_and_check_tree_size(3) @@ -177,7 +180,7 @@ testgroup("cert4") result5 = do_add_chain(cc4) -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) print_and_check_tree_size(4) @@ -191,7 +194,7 @@ testgroup("cert5") result6 = do_add_chain(cc5) -mergeresult = subprocess.call(["./merge.py"]) +mergeresult = merge() assert_equal(mergeresult, 0, "merge", quiet=True) print_and_check_tree_size(5) -- cgit v1.1