Skip to content

Instantly share code, notes, and snippets.

@ArturT
Last active May 1, 2017 14:40
Show Gist options
  • Save ArturT/8c8c8650679125f7ffae03ccfb3cd84e to your computer and use it in GitHub Desktop.
Save ArturT/8c8c8650679125f7ffae03ccfb3cd84e to your computer and use it in GitHub Desktop.
How to auto balance CI build with RSpec in Queue Mode and yarn tests executed only on first CI node
test:
override:
# run yarn tests only on first CI node
# note we will do yarn install on first CI node so other CI nodes can run rspec tests in the mean time
- case $CIRCLE_NODE_INDEX in 0) bundle exec yarn install; yarn flow -- check; yarn test -- --runInBand ;; esac:
parallel: true # Caution: there are 8 spaces indentation!
# Step for Dynamic RSpec allocation
# It will auto balance the whole build
- bundle exec rake knapsack_pro:queue:rspec:
parallel: true # Caution: there are 8 spaces indentation!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment