the build will pass unless you return an exit code of 1. Can you check the exit code on your build, if it comes back as 0 then that is your problem, you’ll need to find a way to return exit code 1 when your tests fail. Not sure how to do that with rake. But this might help https://circleci.com/docs/parallel-manual-setup/#manual-balancing
We use an adapted version of that balancing script.
# We set the ex var to 0 in the beginning
for testfile in $(find ./test -name "*.py" | sort); do
if [ $(($i % $CIRCLE_NODE_TOTAL)) -eq $CIRCLE_NODE_INDEX ]
# We put this extra piece in here to set $ex=1 when the tests fail.
if [ $? = 1 ]; then
# Then at the end we exit with the $ex, if any tests have failed, then $ex will be 1, and this will trigger the build to fail
This script is to run tests on multiple containers, but maybe you can adapt this script to exit the tests properly.