]> git.sur5r.net Git - u-boot/blob - test/run
af1219fdda98a3825796bb3a650024674a7f5820
[u-boot] / test / run
1 #!/bin/bash
2
3 run_test() {
4         $@
5         [ $? -ne 0 ] && result=$((result+1))
6 }
7
8 result=0
9
10 # Run all tests that the standard sandbox build can support
11 run_test ./test/py/test.py --bd sandbox --build
12
13 # Run tests which require sandbox_spl
14 run_test ./test/py/test.py --bd sandbox_spl --build -k \
15                 test/py/tests/test_ofplatdata.py
16
17 # Run tests for the flat DT version of sandbox
18 ./test/py/test.py --bd sandbox_flattree --build
19
20 PYTHONPATH=build-sandbox_spl/scripts/dtc/pylibfdt run_test \
21         ./tools/binman/binman -t
22 run_test ./tools/patman/patman --test
23 run_test ./tools/buildman/buildman -t
24 PYTHONPATH=build-sandbox_spl/scripts/dtc/pylibfdt run_test ./tools/dtoc/dtoc -t
25
26 if [ $result == 0 ]; then
27         echo "Tests passed!"
28 else
29         echo "Tests FAILED"
30         exit 1
31 fi