--- trunk/tests/store-unreadable-json.sh 2008/06/03 02:41:23 130 +++ trunk/tests/store-unreadable-json.sh 2010/01/02 04:55:54 505 @@ -1,6 +1,6 @@ #!/bin/sh # store-unreadable-json.sh - test store when jscoverage.json is not readable -# Copyright (C) 2008 siliconforks.com +# Copyright (C) 2008, 2009, 2010 siliconforks.com # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -18,6 +18,8 @@ set -e +. ./common.sh + # skip on windows uname=`uname` case "$uname" in @@ -37,8 +39,6 @@ trap 'cleanup' 0 1 2 3 15 -export PATH=.:..:../js:$PATH - if [ -z "$VALGRIND" ] then delay=0.2 @@ -47,7 +47,7 @@ fi rm -fr DIR -$VALGRIND jscoverage-server --document-root=recursive --report-dir=DIR > OUT 2> ERR & +$VALGRIND jscoverage-server --no-highlight --document-root=recursive --report-dir=DIR > OUT 2> ERR & server_pid=$! server_port=8080 @@ -56,7 +56,7 @@ cat store.json | sed "s/@PREFIX@/\\//g" > TMP wget --post-file=TMP -q -O- http://127.0.0.1:8080/jscoverage-store > /dev/null cat store.expected.json | sed "s/@PREFIX@/\\//g" > TMP -js json-cmp.js TMP DIR/jscoverage.json +json_cmp TMP DIR/jscoverage.json chmod -r DIR/jscoverage.json