-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
54 additions
and
61 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,7 @@ on: | |
|
||
paths-ignore: | ||
- '**/README.md' | ||
- 'test/**' | ||
|
||
pull_request: | ||
branches: [ master ] | ||
|
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 |
---|---|---|
|
@@ -7,6 +7,7 @@ on: | |
|
||
paths-ignore: | ||
- '**/README.md' | ||
- 'test/**' | ||
|
||
workflow_dispatch: | ||
|
||
|
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 was deleted.
Oops, something went wrong.
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,33 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
trap 'last_command=$current_command; current_command=$BASH_COMMAND' DEBUG | ||
trap 'echo "$0: \"${last_command}\" command failed with exit code $?"' ERR | ||
|
||
PACKAGE="mrs_uav_managers" | ||
VERBOSE=1 | ||
|
||
[ "$VERBOSE" = "0" ] && TEXT_OUTPUT="" | ||
[ "$VERBOSE" = "1" ] && TEXT_OUTPUT="-t" | ||
|
||
# build the package | ||
catkin build $PACKAGE # it has to be fully built normally before building with --catkin-make-args tests | ||
catkin build $PACKAGE --catkin-make-args tests | ||
|
||
TEST_FILES=$(find . -name "*.test" -type f -printf "%f\n") | ||
|
||
for TEST_FILE in `echo $TEST_FILES`; do | ||
|
||
# folder for test results | ||
TEST_RESULT_PATH=$(realpath /tmp/$RANDOM) | ||
mkdir -p $TEST_RESULT_PATH | ||
|
||
# run the test | ||
rostest $PACKAGE $TEST_FILE $TEXT_OUTPUT --results-filename=$PACKAGE.test --results-base-dir="$TEST_RESULT_PATH" | ||
|
||
# evaluate the test results | ||
echo test result path is $TEST_RESULT_PATH | ||
catkin_test_results "$TEST_RESULT_PATH" | ||
|
||
done |
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