Skip to content

Commit

Permalink
Docker builds: Add test debug options
Browse files Browse the repository at this point in the history
These can be set temporarily to debug failing tests on Travis CI
  • Loading branch information
zultron committed Oct 19, 2017
1 parent 6053f9c commit f538eb8
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions scripts/build_docker
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
#!/bin/bash -e
#
# Build/cross-build Machinekit in Docker
# Build/cross-build packages and test Machinekit in Docker
#
# This script can be run manually or in Travis CI. Sample manual
# usage, `$PWD` is the `src/` directory:
#
# .travis/docker_build.sh
# This script can be run manually or in Travis CI

###########################################################
# Configuration from environment, CL args and defaults
Expand Down Expand Up @@ -37,7 +34,7 @@ shift $(($OPTIND - 1))
case ${TAG} in
amd64_*)
BUILD_OPTS='-b' # Build all binary packages
RUN_TESTS='runtests tests' # Run tests on build arch
RUN_TESTS='runtests' # Run tests on build arch
;;
i386_*) # Machine arch: i386
BUILD_OPTS="-a i386" # - Set machine arch
Expand Down Expand Up @@ -127,6 +124,10 @@ case $CMD in
)
;;
"test") # RIP build and regression tests
if "$TEST_DEBUG" = true; then
DOCKER_EXTRA_OPTS=( -e MSGD_OPTS=-s -e DEBUG=5 )
fi
TEST_ARGS="${TEST_ARGS:-tests}"
BUILD_CL=( bash -xec "
# Set up build: \`autoconf\` and \`make\`
(
Expand All @@ -147,7 +148,7 @@ case $CMD in
flavor;
# Run regression tests
${RUN_TESTS}"
${RUN_TESTS} ${TEST_ARGS}"
)
;;
*) echo "Unkown command '$CMD'" >&2; exit 1 ;;
Expand Down

0 comments on commit f538eb8

Please sign in to comment.