@@ -13,148 +13,201 @@ function test {
1313 return $status
1414}
1515
16+ function showTestResult {
17+ if [ $1 -eq 0 ]; then
18+ echo " OK"
19+ else
20+ echo " Failed"
21+ fi
22+ }
23+
1624MOCHA_VERSION=` mocha --version`
1725echo " You're running tests with mocha version $MOCHA_VERSION "
1826echo " "
1927
2028echo ' TESTCASE: native (json) reporter'
2129test test/reporter-native-json/index.sh
22- echo $?
30+ showTestResult $?
31+
2332echo ' TESTCASE: native (tap) reporter'
2433test test/reporter-native-tap/index.sh
25- echo $?
34+ showTestResult $?
35+
2636echo ' TESTCASE: custom (teamcity) reporter'
2737test test/reporter-custom-teamcity/index.sh
28- echo $?
38+ showTestResult $?
39+
2940echo ' TESTCASE: custom (jenkins) reporter'
3041test test/reporter-custom-jenkins/index.sh
31- echo $?
42+ showTestResult $?
43+
3244echo ' TESTCASE: custom (mochawesome) reporter'
3345test test/reporter-custom-mochawesome/index.sh
34- echo $?
46+ showTestResult $?
47+
3548echo ' TESTCASE: custom (allure) reporter'
3649test test/reporter-custom-allure/index.sh
37- echo $?
50+ showTestResult $?
51+
3852echo ' TESTCASE: cli target'
3953test test/cli-target/index.sh
40- echo $?
54+ showTestResult $?
55+
4156echo ' TESTCASE: pwd-based reporter'
4257test test/reporter-pwd/index.sh
43- echo $?
58+ showTestResult $?
59+
4460echo ' TESTCASE: reporter emits events as soon as they come from subprocess'
4561test test/reporter-log/index.js
46- echo $?
62+ showTestResult $?
63+
4764echo ' TESTCASE: parallel'
4865test test/parallel/parallel.sh
49- echo $?
66+ showTestResult $?
67+
5068echo ' TESTCASE: parallel order'
5169test test/parallel-order/index.js
52- echo $?
70+ showTestResult $?
71+
5372echo ' TESTCASE: max parallel tests'
5473test test/max-parallel/index.sh
55- echo $?
74+ showTestResult $?
75+
5676echo ' TESTCASE: max parallel equal 1'
5777test test/max-parallel-1/index.sh
58- echo $?
78+ showTestResult $?
79+
5980echo ' TESTCASE: max parallel tests with empty ones'
6081test test/max-parallel-empty/index.sh
61- echo $?
82+ showTestResult $?
83+
6284echo ' TESTCASE: only tests run'
6385test test/only-tests-run/index.js
64- echo $?
86+ showTestResult $?
87+
6588echo ' TESTCASE: nesting'
6689test test/nesting/nesting.sh
67- echo $?
90+ showTestResult $?
91+
6892echo ' TESTCASE: describe inside describe'
6993test test/describe-inside-describe/index.js
70- echo $?
94+ showTestResult $?
95+
7196echo ' TESTCASE: missing test'
7297test test/missing-test/index.js
73- echo $?
98+ showTestResult $?
99+
74100echo ' TESTCASE: console logs'
75101test test/console-log-inject/index.js
76- echo $?
102+ showTestResult $?
103+
77104echo ' TESTCASE: global hooks'
78105test test/global-hooks/index.sh
79- echo $?
106+ showTestResult $?
107+
80108echo ' TESTCASE: global hooks with required files'
81109test test/global-hooks-require/index.sh
82- echo $?
110+ showTestResult $?
111+
83112echo ' TESTCASE: global hooks with directory as a tests source'
84113test test/global-hooks-directory/index.sh
85- echo $?
114+ showTestResult $?
115+
86116echo ' TESTCASE: --recursive option if no target is set'
87117test test/recursive-no-target/index.js
88- echo $?
118+ showTestResult $?
119+
89120echo ' TESTCASE: total time'
90121test test/total-time/index.js
91- echo $?
122+ showTestResult $?
123+
92124echo ' TESTCASE: timeouts exit code'
93125test test/timeouts-exit-code/index.sh
94- echo $?
126+ showTestResult $?
127+
95128echo ' TESTCASE: no timeouts'
96129test test/no-timeouts/index.sh
97- echo $?
130+ showTestResult $?
131+
98132echo ' TESTCASE: js compilers support'
99133test test/js-compilers/index.sh
100- echo $?
134+ showTestResult $?
135+
101136echo ' TESTCASE: js compilers with files support'
102137test test/js-compilers-1/index.sh
103- echo $?
138+ showTestResult $?
139+
104140echo ' TESTCASE: js compilers with --require support'
105141test test/js-compilers-2/index.sh
106- echo $?
142+ showTestResult $?
143+
107144echo ' TESTCASE: reporter with options'
108145test test/reporter-options/index.sh
109- echo $?
146+ showTestResult $?
147+
110148echo ' TESTCASE: mocha.opts'
111149test test/mocha-opts/index.sh
112- echo $?
150+ showTestResult $?
151+
113152echo ' TESTCASE: syntax errors'
114153test test/syntax-errors/index.js
115- echo $?
154+ showTestResult $?
155+
116156echo ' TESTCASE: --require option support'
117157test test/require-option/index.sh
118- echo $?
158+ showTestResult $?
159+
119160echo ' TESTCASE: run programmatically (base API)'
120161test test/run-programmatically/callback/index.js
121- echo $?
162+ showTestResult $?
163+
122164echo ' TESTCASE: run programmatically (reporter.done is called)'
123165test test/run-programmatically/reporter-done/index.js
124- echo $?
166+ showTestResult $?
167+
125168echo ' TESTCASE: --no-exit option support'
126169test test/reporter-end-no-exit/index.js
127- echo $?
170+ showTestResult $?
171+
128172echo ' TESTCASE: node add-on'
129173test test/node-addon/index.sh
130- echo $?
174+ showTestResult $?
175+
131176echo ' TESTCASE: skip-suite'
132177test test/skip-suite/index.sh
133- echo $?
178+ showTestResult $?
179+
134180echo ' TESTCASE: skip-test'
135181test test/skip-test/index.sh
136- echo $?
182+ showTestResult $?
183+
137184echo ' TESTCASE: --delay option support'
138185test test/delay/index.js
139- echo $?
186+ showTestResult $?
187+
140188echo ' TESTCASE: --retries option support'
141189test test/retries/index.js
142- echo $?
190+ showTestResult $?
191+
143192echo ' TESTCASE: --exit option support'
144193test test/exit/index.js
145- echo $?
194+ showTestResult $?
195+
146196echo ' TESTCASE: --retries plus all tests fail'
147197test test/retries-all-fail/index.js
148- echo $?
198+ showTestResult $?
199+
149200echo ' TESTCASE: --retries and --bail should work well together'
150201test test/bail-and-retries/index.js
151- echo $?
202+ showTestResult $?
203+
152204echo ' TESTCASE: subprocess exits before sending an end message'
153205test test/no-subprocess-end/index.js
154- echo $?
206+ showTestResult $?
207+
155208echo ' TESTCASE: unhandled rejections should not force subprocess to exit'
156209test test/q-promises/index.js
157- echo $?
210+ showTestResult $?
158211
159212echo " Passes: $PASSES Failes: $FAILES "
160213
0 commit comments