Debian Codegraph @

mtest/bww/io/iotest

raw symbols SCIP
1 #!/bin/bashscip-shell filesystem . . `/bin/bash`.
2
3 # simple standalone iotest for BWW import
4 # run in mtest/bww/io directory as "./iotest"
5
6 # Linux
7 #MSCORE=../../../build.debug/mscore/mscore
8 # OS X terminal build
9 #MSCORE=../../../applebuild/mscore.app/Contents/MacOS/mscore
10 # OS X Xcode build
11 MSCORE=../../../build.xcode/mscore/Debug/mscore.app/Contents/MacOS/mscore
12
13 echoscip-shell system . . echo. "----------------------------------------------"
14 echoscip-shell system . . echo. "Regression Tests for MuseScore BWW import"
15 echoscip-shell system . . echo. "----------------------------------------------"
16 echoscip-shell system . . echo.
17 $MSCORE -v
18 echoscip-shell system . . echo.
19
20
21 bww_files=`catscip-shell system . . cat. tst_bww_io.cpp | grepscip-shell system . . grep. "{ bwwIoTest" | awkscip-shell system . . awk. -F\" '{print $2}' | sortscip-shell system . . sort.`
22 testcount=0
23 failures=0
24
25 rwtestBwwscip-shell shell shell-project 0.0.0 rwtestBww().() {
26 echoscip-shell system . . echo. -n "testing load/save $1.bww";
27 $MSCORE $1.bww -d -o mops.xml &> /dev/nullscip-shell filesystem . . `/dev/null`.
28 if diffscip-shell system . . diff. -q $1.xml mops.xml &> /dev/nullscip-shell filesystem . . `/dev/null`.; then
29 echoscip-shell system . . echo. -e "\r\t\t\t\t\t\t...OK";
30 else
31 echoscip-shell system . . echo. -e "\r\t\t\t\t\t\t...FAILED";
32 failures=$(($failures+1));
33 echoscip-shell system . . echo. "+++++++++DIFF++++++++++++++"
34 diffscip-shell system . . diff. $1.xml mops.xml
35 echoscip-shell system . . echo. "+++++++++++++++++++++++++++"
36 fi
37 rmscip-shell system . . rm. mops.xml
38 testcount=$(($testcount+1))
39 }
40
41 rwtestAllBwwscip-shell shell shell-project 0.0.0 rwtestAllBww().() {
42 for f in $bww_files; do
43 rwtestBwwscip-shell shell shell-project 0.0.0 rwtestBww(). $f
44 done
45 }
46
47 usagescip-shell shell shell-project 0.0.0 usage().() {
48 echoscip-shell system . . echo. "usage: $0"
49 echoscip-shell system . . echo.
50 exit 1
51 }
52
53 if [scip-shell system . . `[`. $# -eq 0 ]; then
54 rwtestAllBwwscip-shell shell shell-project 0.0.0 rwtestAllBww().
55 else
56 usagescip-shell shell shell-project 0.0.0 usage().
57 fi
58
59 echoscip-shell system . . echo.
60 echoscip-shell system . . echo. "$testcount test(s), $failures failure(s)"