OLD | NEW |
1 #!/bin/bash | 1 #!/bin/bash |
2 | 2 |
3 # Tests for our tools. | 3 # Tests for our tools. |
4 # | 4 # |
5 # TODO: currently, this only passes on Linux (which is the platform that | 5 # TODO: currently, this only passes on Linux (which is the platform that |
6 # the housekeeper bot runs on, e.g. | 6 # the housekeeper bot runs on, e.g. |
7 # http://70.32.156.51:10117/builders/Skia_PerCommit_House_Keeping/builds/1415/st
eps/RunToolSelfTests/logs/stdio ) | 7 # http://70.32.156.51:10117/builders/Skia_PerCommit_House_Keeping/builds/1415/st
eps/RunToolSelfTests/logs/stdio ) |
8 # See https://code.google.com/p/skia/issues/detail?id=677 | 8 # See https://code.google.com/p/skia/issues/detail?id=677 |
9 # ('make tools/tests/run.sh work cross-platform') | 9 # ('make tools/tests/run.sh work cross-platform') |
10 # Ideally, these tests should pass on all development platforms... | 10 # Ideally, these tests should pass on all development platforms... |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 # | 210 # |
211 | 211 |
212 # Parse a collection of bench data | 212 # Parse a collection of bench data |
213 PLATFORM=Perf-Android-Nexus7-Tegra3-Arm7-Release | 213 PLATFORM=Perf-Android-Nexus7-Tegra3-Arm7-Release |
214 REVISION=69c9e1a7261a3c8361e2b2c109d6340862149e34 | 214 REVISION=69c9e1a7261a3c8361e2b2c109d6340862149e34 |
215 download_bench_rawdata $PLATFORM $REVISION "$BENCHDATA_FILE_SUFFIXES_NO_INDIVIDU
AL_TILES" | 215 download_bench_rawdata $PLATFORM $REVISION "$BENCHDATA_FILE_SUFFIXES_NO_INDIVIDU
AL_TILES" |
216 download_bench_rawdata $PLATFORM $REVISION "$BENCHDATA_FILE_SUFFIXES_YES_INDIVID
UAL_TILES" | 216 download_bench_rawdata $PLATFORM $REVISION "$BENCHDATA_FILE_SUFFIXES_YES_INDIVID
UAL_TILES" |
217 benchalert_test $PLATFORM $REVISION | 217 benchalert_test $PLATFORM $REVISION |
218 | 218 |
219 # | 219 # |
220 # Run self test for skimage ... | |
221 # | |
222 | |
223 COMMAND="python tools/tests/skimage_self_test.py" | |
224 echo "$COMMAND" | |
225 $COMMAND | |
226 ret=$? | |
227 if [ $ret -ne 0 ]; then | |
228 echo "skimage self tests failed." | |
229 exit 1 | |
230 fi | |
231 | |
232 # | |
233 # Test rebaseline.py ... | 220 # Test rebaseline.py ... |
234 # | 221 # |
235 | 222 |
236 REBASELINE_INPUT=tools/tests/rebaseline/input | 223 REBASELINE_INPUT=tools/tests/rebaseline/input |
237 REBASELINE_OUTPUT=tools/tests/rebaseline/output | 224 REBASELINE_OUTPUT=tools/tests/rebaseline/output |
238 rebaseline_test "$REBASELINE_INPUT/json1" "--actuals-base-url $REBASELINE_INPUT/
json1 --builders Test-Android-GalaxyNexus-SGX540-Arm7-Debug Test-Win7-ShuttleA-H
D2000-x86-Release" "$REBASELINE_OUTPUT/using-json1-expectations" | 225 rebaseline_test "$REBASELINE_INPUT/json1" "--actuals-base-url $REBASELINE_INPUT/
json1 --builders Test-Android-GalaxyNexus-SGX540-Arm7-Debug Test-Win7-ShuttleA-H
D2000-x86-Release" "$REBASELINE_OUTPUT/using-json1-expectations" |
239 rebaseline_test "$REBASELINE_INPUT/json1" "--actuals-base-url $REBASELINE_INPUT/
json1 --bugs 1234 5678 --builders Test-Android-GalaxyNexus-SGX540-Arm7-Debug Tes
t-Win7-ShuttleA-HD2000-x86-Release --notes notes_content --unreviewed" "$REBASEL
INE_OUTPUT/marked-unreviewed" | 226 rebaseline_test "$REBASELINE_INPUT/json1" "--actuals-base-url $REBASELINE_INPUT/
json1 --bugs 1234 5678 --builders Test-Android-GalaxyNexus-SGX540-Arm7-Debug Tes
t-Win7-ShuttleA-HD2000-x86-Release --notes notes_content --unreviewed" "$REBASEL
INE_OUTPUT/marked-unreviewed" |
240 rebaseline_test "$REBASELINE_INPUT/json1" "--actuals-base-url $REBASELINE_INPUT/
json1 --add-new --builders Test-Android-GalaxyNexus-SGX540-Arm7-Debug Test-Mac10
.6-MacMini4.1-GeForce320M-x86-Release Test-Win7-ShuttleA-HD2000-x86-Release" "$R
EBASELINE_OUTPUT/add-new" | 227 rebaseline_test "$REBASELINE_INPUT/json1" "--actuals-base-url $REBASELINE_INPUT/
json1 --add-new --builders Test-Android-GalaxyNexus-SGX540-Arm7-Debug Test-Mac10
.6-MacMini4.1-GeForce320M-x86-Release Test-Win7-ShuttleA-HD2000-x86-Release" "$R
EBASELINE_OUTPUT/add-new" |
241 | 228 |
242 # | 229 # |
243 # Test jsondiff.py ... | 230 # Test jsondiff.py ... |
244 # | 231 # |
245 | 232 |
246 JSONDIFF_INPUT=tools/tests/jsondiff/input | 233 JSONDIFF_INPUT=tools/tests/jsondiff/input |
247 JSONDIFF_OUTPUT=tools/tests/jsondiff/output | 234 JSONDIFF_OUTPUT=tools/tests/jsondiff/output |
248 jsondiff_test "$JSONDIFF_INPUT/old.json $JSONDIFF_INPUT/new.json" "$JSONDIFF_OUT
PUT/old-vs-new" | 235 jsondiff_test "$JSONDIFF_INPUT/old.json $JSONDIFF_INPUT/new.json" "$JSONDIFF_OUT
PUT/old-vs-new" |
249 | 236 |
250 | 237 |
| 238 # |
| 239 # Launch all the self-tests which have been written in Python. |
| 240 # |
| 241 # TODO: Over time, we should move all of our tests into Python, and delete |
| 242 # the bash tests above. |
| 243 # See https://code.google.com/p/skia/issues/detail?id=677 |
| 244 # ('make tools/tests/run.sh work cross-platform') |
| 245 # |
| 246 |
| 247 COMMAND="python tools/tests/run_all.py" |
| 248 echo "$COMMAND" |
| 249 $COMMAND |
| 250 ret=$? |
| 251 if [ $ret -ne 0 ]; then |
| 252 echo "failure in Python self-tests; see stack trace above" |
| 253 exit 1 |
| 254 fi |
| 255 |
| 256 |
251 echo "All tests passed." | 257 echo "All tests passed." |
OLD | NEW |