Skip to content

Instantly share code, notes, and snippets.

@carpeliam
Created January 5, 2017 14:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save carpeliam/d257fed7eaed6a26a8304c38da3da4ed to your computer and use it in GitHub Desktop.
Save carpeliam/d257fed7eaed6a26a8304c38da3da4ed to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
./gradlew bootRun > /dev/null 2>&1 &
GRADLE_PID=$!
printf 'starting server'
until $(curl --output /dev/null --silent --head http://localhost:8080); do
printf '.'
sleep 3
done
echo "server up, running specs..."
pushd journey_specs
rspec
RSPEC_RESULTS=$?
popd
echo "killing ${GRADLE_PID}, rspec resulted in ${RSPEC_RESULTS}"
kill $GRADLE_PID
exit $RSPEC_RESULTS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment