2 # memory regression suite.
3 # runs some tests, with some define combinations and stores it in .result and .data files.
5 # TODO: need to check write perms to the .testbox/* (mixed web/cli perms)
6 # TODO: need to add the ploticus path
8 #if [ -d .testbox/page_data -a ! -w .testbox/page_data/AllPages ]; then
9 # rm -rf .testbox/test_*.*db*
13 tests="test=SetupWiki test=AllPagesTest test=DumpHtml"
15 if [ -z $prefix ]; then prefix="439dba"; fi
18 for define in USECACHE ENABLE_USER_NEW; do
19 file1="${prefix}_${define}_true"
20 file2="${prefix}_${define}_false"
21 php -Cq -d register_argc_argv=1 test.php -d${define}=true level=2 debug=9 db=$db $tests | tee ${file1}.result
22 ./prepare_pl ${file1} -nopl
23 #pl -png -o ${file1}.png ${file1}.ploticus
25 php -Cq -d register_argc_argv=1 test.php -d${define}=false level=2 debug=9 db=$db $tests | tee ${file2}.result
26 ./prepare_pl ${file2} -nopl
27 #pl -png -o ${file2}.png ${file2}.ploticus
30 # get the relevant mem numbers (testsetupwiki, test99dumphtml)
31 # combine the results and display the graph
32 ./combine_define.pl $prefix
33 echo "" >> "${prefix}_combine_define.data"
34 #pl -png -o all_$db.png -prefab vbars data=all_$db.data delim=tab x=2 y=1 xstep=2 barwidth=line ylbl="memory (kb)" title="$db $title" xlbl="consecutive tests" stubvert=yes ygrid=yes ylbldet="adjust=-0.1,0" xlbldet="adjust=0,-1.2" # vals=yes