summaryrefslogtreecommitdiff
path: root/tools/testcase1.py
diff options
context:
space:
mode:
authorMagnus Ahltorp <map@kth.se>2017-03-01 17:04:39 +0100
committerMagnus Ahltorp <map@kth.se>2017-03-02 01:09:18 +0100
commite67187c38e4e5a97ab971554d8acf9466e9775c2 (patch)
tree5d7bad771d815f00a2df57433423b9398a82a19b /tools/testcase1.py
parent163fdaeaf8fc1bc43923420309ba4a6b3ef51e11 (diff)
Refactor tests
Diffstat (limited to 'tools/testcase1.py')
-rwxr-xr-xtools/testcase1.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/tools/testcase1.py b/tools/testcase1.py
index fb081e5..a616841 100755
--- a/tools/testcase1.py
+++ b/tools/testcase1.py
@@ -192,11 +192,11 @@ def mergestatus(configfile, localconfigfile):
def merge(expected=None, wait=0):
rv = subprocess.call([toolsdir + "/merge", "--config", testdir + "/catlfish-test.cfg",
- "--localconfig", testdir + "/catlfish-test-local-merge.cfg"])
+ "--localconfig", testdir + "/catlfish-test-local-merge-1.cfg"])
if rv:
return rv
for i in range(10):
- mergestatus(testdir + "/catlfish-test.cfg", testdir + "/catlfish-test-local-merge.cfg")
+ mergestatus(testdir + "/catlfish-test.cfg", testdir + "/catlfish-test-local-merge-1.cfg")
if i < wait:
sleep(1)
continue
@@ -214,6 +214,7 @@ for baseurl in baseurls:
testgroup("cert1")
result1 = do_add_chain(cc1, baseurls[0])
+result2 = do_add_chain(cc1, baseurls[0])
mergeresult = merge(expected=1)
assert_equal(mergeresult, 0, "merge", quiet=True, fatal=True)
@@ -224,9 +225,10 @@ for baseurl in baseurls:
print_and_check_tree_size(1, baseurl)
size_sth[1] = base64.b64decode(get_sth(baseurls[0])["sha256_root_hash"])
-result2 = do_add_chain(cc1, baseurls[0])
+result3 = do_add_chain(cc1, baseurls[0])
assert_equal(result2["timestamp"], result1["timestamp"], "timestamp")
+assert_equal(result3["timestamp"], result1["timestamp"], "timestamp")
mergeresult = merge(expected=1, wait=3)
assert_equal(mergeresult, 0, "merge", quiet=True, fatal=True)