1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
|
#!/bin/bash -e
# This script is used to run the tests for this project in a Docker container.
#
# bin/test-in-docker [test_file_name ...]
#
# If no test file names are provided, all tests in the `tests/units` directory will be run.
cd "$( dirname "${BASH_SOURCE[0]}" )"/..
export COMPOSE_FILE=tests/docker-compose.yml
export COMPOSE_PROJECT_NAME=ruby-git_dev
docker-compose rm -svf
docker-compose build --force-rm
docker-compose run --rm tester "$@" && docker-compose rm -svf || ( docker-compose logs && exit 1 )
|