Revision 166
Added by Aaron Marcuse-Kubitza about 13 years ago
scripts/test/map | ||
---|---|---|
40 | 40 |
|
41 | 41 |
function toXml() |
42 | 42 |
{ |
43 |
out="$stem.$out_fmt.xml" |
|
43 |
local out="output/$stem.$out_fmt${method+.$method}.xml" |
|
44 |
local accepted="accepted_output/$stem.$out_fmt.xml" |
|
44 | 45 |
( |
45 | 46 |
set -x |
46 |
../map "$map" >"output/$out" || exit
|
|
47 |
diff "accepted_output/$out" "output/$out" || true # ignore exit status
|
|
48 |
) |
|
47 |
../map "$map" >"$out" || exit |
|
48 |
diff "$accepted" "$out" || true # ignore exit status
|
|
49 |
) || exit # abort tester
|
|
49 | 50 |
} |
50 | 51 |
|
51 | 52 |
function toDb() |
... | ... | |
61 | 62 |
for out_fmt in VegX VegBank; do map toXml; done # source to XML |
62 | 63 |
out_fmt=VegBank |
63 | 64 |
# VegX to VegBank |
64 |
( |
|
65 |
src=VegX |
|
66 |
in="output/$stem.$src.xml" |
|
67 |
stem="$stem.2-step" |
|
68 |
map toXml |
|
69 |
) || exit |
|
65 |
(src=VegX in="output/$stem.$src.xml" method=via_$src; map toXml) || exit |
|
70 | 66 |
map toDb # source to VegBank db |
71 | 67 |
done |
Also available in: Unified diff
test/map: Compare via-VegX output to direct output