Date: | 2010-10-12 17:32:15 (13 years 5 months ago) |
---|---|
Author: | werner |
Commit: | 02518334f22ff1749b0533391faab906e2546113 |
Message: | Updated regression tests for output change in r5974 and improved
handling of cores. - test/structure, test/del_vec, test/frame_ref, test/meas_qual, test/del_frame: added newline after "unit" directive (reported by Xiangfu Liu) - test/Common: new function expect_sed for post-processing of test output - test/tsort: use expect_sed to ignore "(core dumped") after "Aborted" - test/Common: if there is a file called "core", don't run it - Makefile (clean): remove test/core git-svn-id: http://svn.openmoko.org/trunk/eda/fped@5978 99fdad57-331a-0410-800a-d7fa5415bdb3 |
Files: |
Makefile (2 diffs) test/Common (1 diff) test/del_frame (4 diffs) test/del_vec (4 diffs) test/frame_ref (6 diffs) test/meas_qual (1 diff) test/structure (6 diffs) test/tsort (1 diff) |
Change Details
Makefile | ||
---|---|---|
162 | 162 | LANG= sh -c \ |
163 | 163 | 'passed=0 && cd test && \ |
164 | 164 | for n in [a-z]*; do \ |
165 | SCRIPT=$$n CWD_PREFIX=.. . ./$$n; done; \ | |
165 | [ $$n != core ] && SCRIPT=$$n CWD_PREFIX=.. . ./$$n; done; \ | |
166 | 166 | echo "Passed all $$passed tests"' |
167 | 167 | |
168 | 168 | valgrind: |
... | ... | |
173 | 173 | clean: |
174 | 174 | rm -f $(OBJS) $(XPMS:%=icons/%) $(XPMS:%.xpm=icons/%.ppm) |
175 | 175 | rm -f lex.yy.c y.tab.c y.tab.h y.output .depend $(OBJS:.o=.d) |
176 | rm -f __dbg????.png _tmp* | |
176 | rm -f __dbg????.png _tmp* test/core | |
177 | 177 | |
178 | 178 | # ----- Install / uninstall --------------------------------------------------- |
179 | 179 |
test/Common | ||
---|---|---|
71 | 71 | } |
72 | 72 | |
73 | 73 | |
74 | expect_sed() | |
75 | { | |
76 | sed "$1" <_out >_tmp || exit 1 | |
77 | mv _tmp _out | |
78 | shift | |
79 | expect "$@" | |
80 | } | |
81 | ||
82 | ||
74 | 83 | if [ ! -z "$CWD_PREFIX" -a ! -z "$FPED" -a "$FPED" = "${FPED#/}" ]; then |
75 | 84 | FPED="$CWD_PREFIX/$FPED" |
76 | 85 | fi |
test/del_frame | ||
---|---|---|
26 | 26 | |
27 | 27 | package "_" |
28 | 28 | unit mm |
29 | ||
29 | 30 | EOF |
30 | 31 | |
31 | 32 | #------------------------------------------------------------------------------ |
... | ... | |
44 | 45 | |
45 | 46 | package "_" |
46 | 47 | unit mm |
48 | ||
47 | 49 | EOF |
48 | 50 | |
49 | 51 | #------------------------------------------------------------------------------ |
... | ... | |
63 | 65 | |
64 | 66 | package "_" |
65 | 67 | unit mm |
68 | ||
66 | 69 | EOF |
67 | 70 | |
68 | 71 | #------------------------------------------------------------------------------ |
... | ... | |
88 | 91 | |
89 | 92 | package "_" |
90 | 93 | unit mm |
94 | ||
91 | 95 | EOF |
92 | 96 | |
93 | 97 | ############################################################################### |
test/del_vec | ||
---|---|---|
12 | 12 | |
13 | 13 | package "_" |
14 | 14 | unit mm |
15 | ||
15 | 16 | EOF |
16 | 17 | |
17 | 18 | #------------------------------------------------------------------------------ |
... | ... | |
26 | 27 | |
27 | 28 | package "_" |
28 | 29 | unit mm |
30 | ||
29 | 31 | EOF |
30 | 32 | |
31 | 33 | #------------------------------------------------------------------------------ |
... | ... | |
40 | 42 | |
41 | 43 | package "_" |
42 | 44 | unit mm |
45 | ||
43 | 46 | EOF |
44 | 47 | |
45 | 48 | #------------------------------------------------------------------------------ |
... | ... | |
60 | 63 | |
61 | 64 | package "_" |
62 | 65 | unit mm |
66 | ||
63 | 67 | frame f @ |
64 | 68 | EOF |
65 | 69 |
test/frame_ref | ||
---|---|---|
15 | 15 | |
16 | 16 | package "_" |
17 | 17 | unit mm |
18 | ||
18 | 19 | frame f @ |
19 | 20 | EOF |
20 | 21 | |
... | ... | |
32 | 33 | |
33 | 34 | package "_" |
34 | 35 | unit mm |
36 | ||
35 | 37 | frame f @ |
36 | 38 | EOF |
37 | 39 | |
... | ... | |
50 | 52 | |
51 | 53 | package "_" |
52 | 54 | unit mm |
55 | ||
53 | 56 | v: vec @(0mm, 0mm) |
54 | 57 | frame f . |
55 | 58 | EOF |
... | ... | |
73 | 76 | |
74 | 77 | package "_" |
75 | 78 | unit mm |
79 | ||
76 | 80 | EOF |
77 | 81 | |
78 | 82 | #------------------------------------------------------------------------------ |
... | ... | |
97 | 101 | |
98 | 102 | package "_" |
99 | 103 | unit mm |
104 | ||
100 | 105 | EOF |
101 | 106 | |
102 | 107 | #------------------------------------------------------------------------------ |
... | ... | |
138 | 143 | |
139 | 144 | package "_" |
140 | 145 | unit mm |
146 | ||
141 | 147 | EOF |
142 | 148 | |
143 | 149 | ############################################################################### |
test/meas_qual | ||
---|---|---|
27 | 27 | |
28 | 28 | package "_" |
29 | 29 | unit mm |
30 | ||
30 | 31 | frame a @ |
31 | 32 | meas c.v >> c.v |
32 | 33 | EOF |
test/structure | ||
---|---|---|
10 | 10 | |
11 | 11 | package "_" |
12 | 12 | unit mm |
13 | ||
13 | 14 | EOF |
14 | 15 | |
15 | 16 | #------------------------------------------------------------------------------ |
... | ... | |
26 | 27 | |
27 | 28 | package "_" |
28 | 29 | unit mm |
30 | ||
29 | 31 | EOF |
30 | 32 | |
31 | 33 | #------------------------------------------------------------------------------ |
... | ... | |
38 | 40 | |
39 | 41 | package "hello" |
40 | 42 | unit mm |
43 | ||
41 | 44 | EOF |
42 | 45 | |
43 | 46 | #------------------------------------------------------------------------------ |
... | ... | |
50 | 53 | |
51 | 54 | package "_" |
52 | 55 | unit mil |
56 | ||
53 | 57 | EOF |
54 | 58 | |
55 | 59 | #------------------------------------------------------------------------------ |
... | ... | |
62 | 66 | |
63 | 67 | package "_" |
64 | 68 | unit mm |
69 | ||
65 | 70 | __0: vec @(1mm, 1mm) |
66 | 71 | EOF |
67 | 72 | |
... | ... | |
85 | 90 | |
86 | 91 | package "_" |
87 | 92 | unit mm |
93 | ||
88 | 94 | frame f @ |
89 | 95 | meas f.a -> f.b |
90 | 96 | EOF |
test/tsort | ||
---|---|---|
126 | 126 | b a |
127 | 127 | } |
128 | 128 | EOF |
129 | expect <<EOF | |
129 | expect_sed 's/Aborted.*/Aborted/' <<EOF | |
130 | 130 | cycle detected in partial order |
131 | Aborted (core dumped) | |
131 | Aborted | |
132 | 132 | EOF |
133 | 133 | |
134 | 134 | # not entirely comfortable about the "Aborted (core dumped)". It's a system |
Branches:
master