From 9e156498685a210047d526059f4c5da6730e468f Mon Sep 17 00:00:00 2001 From: Bob Igo aka human-being Date: Fri, 16 May 2014 11:52:53 +0200 Subject: [PATCH] 7699: update and run again tools.sh; it outputs two DB files for human inspection --- gramps/plugins/tool/toolsdebug.gpr.py | 2 +- test/tools.sh | 23 ++++++++++------------- 2 files changed, 11 insertions(+), 14 deletions(-) diff --git a/gramps/plugins/tool/toolsdebug.gpr.py b/gramps/plugins/tool/toolsdebug.gpr.py index 761bfa22b..4c8d0e171 100644 --- a/gramps/plugins/tool/toolsdebug.gpr.py +++ b/gramps/plugins/tool/toolsdebug.gpr.py @@ -104,7 +104,7 @@ tool_modes = [TOOL_MODE_GUI, TOOL_MODE_CLI] register(TOOL, id = 'populatesources', name = "Populate Sources and Citations", -description = ("This tool generates sources and citations ofr each source in " +description = ("This tool generates sources and citations for each source in " "order to populate the database for testing with significant " "numbers of sources and citations"), version = '1.0', diff --git a/test/tools.sh b/test/tools.sh index 9d6d63406..0eb4acff6 100755 --- a/test/tools.sh +++ b/test/tools.sh @@ -11,41 +11,38 @@ TOP_DIR=`dirname $PWD` TEST_DIR=$TOP_DIR/test -SRC_DIR=$TOP_DIR/src -PRG="python gramps.py" +SRC_DIR=$TOP_DIR/gramps +PRG="python ../Gramps.py" EXAMPLE_XML=$TOP_DIR/example/gramps/example.gramps +MINIMAL_XML=$TOP_DIR/example/gramps/minimal.gramps TOOL_DIR=$TEST_DIR/tools mkdir -p $TOOL_DIR OPTS="-i $EXAMPLE_XML" -TOOLS1="reorder_ids verify chkpoint rebuild dgenstats check" -TOOLS2="chtype cmdref testcasegenerator" +TOOLS1="reorder_ids verify rebuild dgenstats rebuild_genstats rebuild_refmap test_for_date_parser_and_displayer check" # Run all tools on the example data, check at the end echo "" echo "+--------------------------------------------------------------" -echo "| Tools: chtype cmdref $TOOLS1" +echo "| Tools: chtype $TOOLS1" echo "+--------------------------------------------------------------" action= action="$action -a tool -p name=chtype,fromtype=Burial,totype=WeirdType" -action="$action -a tool -p name=cmdref,include=1,target=$TOOL_DIR/junk.xml" for tool in $TOOLS1; do action="$action -a tool -p name=$tool" done -(cd $SRC_DIR; $PRG $OPTS $action) +/bin/rm -f $TOOL_DIR/tools1.gramps +(cd $SRC_DIR; $PRG $OPTS $action -e $TOOL_DIR/tools1.gramps) # Run random test generator on an empty db, preserve the result. echo "" echo "+--------------------------------------------------------------" echo "| Tool: testcasegenerator" echo "+--------------------------------------------------------------" -TEST_DATA=$TOOL_DIR/junk.grdb -if [ -f $TEST_DATA ]; then - rm $TEST_DATA -fi -touch $TEST_DATA -OPTS="-O $TEST_DATA" +TEST_DATA=$MINIMAL_XML +/bin/rm -f $TOOL_DIR/testcases.gramps +OPTS="-i $TEST_DATA -e $TOOL_DIR/testcases.gramps" action="-a tool -p name=testcasegenerator" (cd $SRC_DIR; $PRG $OPTS $action)