Skip to content

Instantly share code, notes, and snippets.

@akirasosa
Created September 13, 2013 07:26
Show Gist options
  • Save akirasosa/6547654 to your computer and use it in GitHub Desktop.
Save akirasosa/6547654 to your computer and use it in GitHub Desktop.
I have a tons of rspec test cases. Here is an easy way to distribute them between Jenkins slaves.
# LABEL was passed from an upstream job. It will be in 0, 1 or 2.
find ./spec -name "*_spec.rb" | awk "NR % 3 == ${LABEL} {print}" | xargs rspec
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment