-
Notifications
You must be signed in to change notification settings - Fork 567
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Improve spec speed #537
Improve spec speed #537
Conversation
* The test is to make sure that json is used * The size of the json is irrelevant really, just that the right library is used and the json is parsed. * Speeds up test suite a gobsmacking amount with parallel tests (~10 mins -> 1 minute)
task :parallel_spec do | ||
require 'parallel_tests/cli' | ||
Rake::Task[:spec_prep].invoke | ||
ParallelTests::CLI.new.run('--type test -t rspec spec/classes spec/defines spec/unit'.split) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Damn just realised I forgot functions, I did think the speed increase was a little too impressive...
EDIT: nvm, functions is only 2 tests, this is speedy 🚗
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nvm, there's only 2 specs in there, this thing really is fast! 💯
Thank you for this pull request! Please check this document for how the Jenkins project handles pull requests. |
e0f3082
to
7906cd4
Compare
Note: Repeated running on a dev machine make this faster: |
Also moves parallel_tests out of development group so it's installed on travis Comparison on an 8 core Mac: ``` $ bundle exec rake parallel_spec 746 examples, 0 failures, 10 pendings Took 66 seconds (1:06) ``` Vs. ``` $ bundle exec rake spec Finished in 3 minutes 4.8 seconds (files took 2.14 seconds to load) 746 examples, 0 failures, 10 pending ```
7906cd4
to
2301f95
Compare
Consistant 2 mins ~ specs in Travis 🎆 |
Travis doesn't like you @petems
|
e589cd4
to
69e2bb2
Compare
Whoops, should be fixed now! 😓 |
WHOOO |
Removes large fixture file, even for non 1.9.3 …
Adds parallel tests rake task …
Comparison on an 8 core Mac:
Vs Vanilla spec:
Changes travis to use parallel specs
Lets speed up that CI!