-
Notifications
You must be signed in to change notification settings - Fork 698
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
meta-oe: recipes-support: dc: Add ptest
Signed-off-by: Ever ATILANO <ever.atilano@smile.fr> Signed-off-by: Yoann Congal <yoann.congal@smile.fr> Signed-off-by: Khem Raj <raj.khem@gmail.com>
- Loading branch information
Showing
2 changed files
with
47 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/sh | ||
|
||
# This script runs tests taken from the github CI for the Double-Conversion library. | ||
# For more information, please see: https://github.com/google/double-conversion/blob/master/.github/workflows/ci.yml#L60 | ||
|
||
# Count the number of failed tests | ||
NUM_FAILS=0 | ||
|
||
# Run all tests using ctest | ||
ctest -V | ||
|
||
# VCount the number of failed tests by checking the LastTest.log file generated by ctest | ||
NUM_FAILS=$(grep -c "Failed" Testing/Temporary/LastTest.log) | ||
|
||
# Run the tests directly as well, just in case we forgot to add it to ctest | ||
test/cctest/cctest | ||
if [ $? -ne 0 ]; then | ||
# If the test failed, increment the number of failed tests | ||
NUM_FAILS=$(expr $NUM_FAILS + 1) | ||
fi | ||
|
||
# Return the number of failed tests | ||
exit $NUM_FAILS |