sauce-archives / sauce_ruby

This is the Ruby client adapter for testing with Sauce Labs, a Selenium-based browser testing service (saucelabs.com).
Apache License 2.0
98 stars 115 forks source link

Super fast tests with parallel_split_test #343

Closed bootstraponline closed 8 years ago

bootstraponline commented 9 years ago

sauce_ruby uses parallel_tests which parallelizes files not tests. Serial execution of tests in a file is a huge performance bottleneck. If all tests were in one file then sauce_ruby wouldn't parallelize anything. Until now the solution was to record the per file timings in a custom junit formatter and then manually split up the file into smaller files. What if we could teach sauce_ruby to automatically parallelize all the tests all the time? This is possible thanks to parallel_split_test

I have setup a test example which runs twice as fast compared to standard parallel_tests. The parallel_split_test sauce_ruby support is in my fork. It's currently a proof of concept. @DylanLacey what do you think about adding this as an optional parallelization mode?

vjong-gpsw commented 9 years ago

parallel_tests does have the --group-by option. It appears that --group-by scenarios would do exactly what you want. https://github.com/grosser/parallel_tests#setup-for-non-rails

It appears that this project is no longer maintained either...

bootstraponline commented 9 years ago

--group-by scenarios - individual cucumber scenarios is for cucumber only. I don't use cucumber. parallel_split_test mostly does what I want except for one bug.

I read about stripe's runner and moved on to using github's test-queue with split support (test-queue-split on rubygems).

sauce_ruby isn't maintained.