aboutsummaryrefslogtreecommitdiff
path: root/android
diff options
context:
space:
mode:
authordigit@chromium.org <digit@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e>2012-10-09 17:15:06 +0000
committerdigit@chromium.org <digit@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e>2012-10-09 17:15:06 +0000
commitb52be69e590ac13f30d104cb713cc31348547523 (patch)
tree39154b23dd962d08b3f31d6c64b278de9378251d /android
parentDon't bail if a thread's stack pointer is invalid (diff)
downloadbreakpad-b52be69e590ac13f30d104cb713cc31348547523.tar.xz
Fix the Android unit tests.
- One of the unit test binaries refused to link due to missing linker flags. - The WriteDSODebug() function now works on Android, so do not special-case it anymore. - Ensure android/run-checks.sh will complain properly if the client unit test suite fails on Android. It used to consider that such failures were acceptable. Note that it still considers failures when running the tools and processor test suite on the device normal (fixing this is a lot harder, and these parts of Breakpad typically never run on a device, but on the host). Review URL: https://breakpad.appspot.com/482002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1066 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'android')
-rwxr-xr-xandroid/run-checks.sh37
1 files changed, 21 insertions, 16 deletions
diff --git a/android/run-checks.sh b/android/run-checks.sh
index bdfae8b7..400f7561 100755
--- a/android/run-checks.sh
+++ b/android/run-checks.sh
@@ -369,28 +369,33 @@ else
ACTION="Running"
TESTS_ENVIRONMENT=
fi
-if [ "$ALL_TESTS" ]; then
- dump "$ACTION full Android unit tests."
-else
- dump "$ACTION Android client library unit tests."
-fi
(
PATH="$NDK_STANDALONE/bin:$PATH"
run cd "$TMPDIR"/build-target &&
- if [ -z "$ALL_TESTS" ]; then
- # Reconfigure to avoid building the unit tests for the tools
- # and processor, unless --all-tests is used.
+ # Reconfigure to only run the client unit test suite.
+ # This one should _never_ fail.
+ dump "$ACTION Android client library unit tests."
+ run2 "$PROGDIR"/../configure --prefix="$TMPTARGET" \
+ --host="$GNU_CONFIG" \
+ --disable-tools \
+ --disable-processor &&
+ run make -j$NUM_JOBS check $TESTS_ENVIRONMENT || exit $?
+
+ if [ "$ALL_TESTS" ]; then
+ dump "$ACTION Tools and processor unit tests."
+ # Reconfigure to run the processor and tools tests.
+ # Most of these fail for now, so do not worry about it.
run2 "$PROGDIR"/../configure --prefix="$TMPTARGET" \
- --host="$GNU_CONFIG" \
- --disable-tools \
- --disable-processor
- fi &&
- run make -j$NUM_JOBS check $TESTS_ENVIRONMENT
+ --host="$GNU_CONFIG" &&
+ run make -j$NUM_JOBS check $TESTS_ENVIRONMENT
+ if [ $? != 0 ]; then
+ dump "Tools and processor unit tests failed as expected. \
+Use --verbose for results."
+ fi
+ fi
)
-if [ -z "$NO_DEVICE" ] && verbosity_is_lower_than 2; then
- dump " Unit tests failed as expected. Use --verbose to see results."
-fi
+fail_panic "Client library unit test suite failed!"
# Copy sources to temporary directory
PROJECT_DIR=$TMPDIR/project