diff options
author | Simone Weiss <simone.weiss@elektrobit.com> | 2022-08-12 11:39:24 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-14 08:13:32 +0100 |
commit | 271bbd9cc3d492402aaa95ffa295949403c2bfd0 (patch) | |
tree | cdb9887ec271bae01a3069d1fac2a78ca4649551 /meta/recipes-devtools/json-c/json-c | |
parent | c80405aa9d32f5e9b7eb50fe2ddcec5f8e8cf20d (diff) | |
download | poky-271bbd9cc3d492402aaa95ffa295949403c2bfd0.tar.gz |
json-c: Add ptest for json-c
Adapt json-c recipe to compile and deploy a ptest for json-c.
Also add a small script for executing the tests.
All tests were successful on a trial and took around 20 seconds.
(From OE-Core rev: 757a5fbdeed58573c40d6e21475cc516aa49fd1c)
Signed-off-by: Simone Weiß <simone.weiss@elektrobit.com>
Signed-off-by: Kai Tomerius <kai.tomerius@elektrobit.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/json-c/json-c')
-rw-r--r-- | meta/recipes-devtools/json-c/json-c/run-ptest | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/meta/recipes-devtools/json-c/json-c/run-ptest b/meta/recipes-devtools/json-c/json-c/run-ptest new file mode 100644 index 0000000000..9ee6095ea2 --- /dev/null +++ b/meta/recipes-devtools/json-c/json-c/run-ptest | |||
@@ -0,0 +1,20 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | # This script is used to run json-c test suites | ||
4 | cd tests | ||
5 | |||
6 | ret_val=0 | ||
7 | for i in test*.test; do | ||
8 | # test_basic is not an own testcase, just | ||
9 | # contains common code of other tests | ||
10 | if [ "$i" != "test_basic.test" ]; then | ||
11 | if ./$i > json-c_test.log 2>&1 ; then | ||
12 | echo PASS: $i | ||
13 | else | ||
14 | ret_val=1 | ||
15 | echo FAIL: $i | ||
16 | fi | ||
17 | fi | ||
18 | done | ||
19 | |||
20 | exit $ret_val | ||