summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtest/scripts/continuous-merge-test.sh3
-rw-r--r--test/scripts/testutils.sh4
-rw-r--r--tools/mergetools.py2
3 files changed, 7 insertions, 2 deletions
diff --git a/test/scripts/continuous-merge-test.sh b/test/scripts/continuous-merge-test.sh
index 3bb6de2..1e944b6 100755
--- a/test/scripts/continuous-merge-test.sh
+++ b/test/scripts/continuous-merge-test.sh
@@ -5,12 +5,13 @@ set -o errexit
top_srcdir=$(cd $(dirname $0)/../..; pwd)
-. ${top_srcdir}/test/test.shvars
+. ${top_srcdir}/test/scripts/testutils.sh
SCRIPTS=${top_srcdir}/test/scripts
tests_start() {
${SCRIPTS}/light-system-test-start.sh
+ init_log
${SCRIPTS}/continuous-merge-start.sh &
}
diff --git a/test/scripts/testutils.sh b/test/scripts/testutils.sh
index faa7026..ecefe2b 100644
--- a/test/scripts/testutils.sh
+++ b/test/scripts/testutils.sh
@@ -30,3 +30,7 @@ check_sth() {
do_merge() {
${top_srcdir}/tools/merge --config ${top_srcdir}/test/catlfish-test.cfg --timing --localconfig ${top_srcdir}/test/catlfish-test-local-merge.cfg $@ || fail "Merge failed"
}
+
+init_log() {
+ ${top_srcdir}/tools/initlog.py --config ${top_srcdir}/test/catlfish-test.cfg --localconfig ${top_srcdir}/test/catlfish-test-local-merge.cfg || fail "Log init failed"
+}
diff --git a/tools/mergetools.py b/tools/mergetools.py
index beb41bf..1ff3fa5 100644
--- a/tools/mergetools.py
+++ b/tools/mergetools.py
@@ -38,7 +38,7 @@ def get_nfetched(currentsizefile, logorderfile):
try:
limit = json.loads(open(currentsizefile).read())
except (IOError, ValueError):
- return 0
+ return -1
if limit['index'] >= 0:
with open(logorderfile, 'r') as f:
f.seek(limit['index']*65)