Readme.md in parallel_tests-4.3.0 vs Readme.md in parallel_tests-4.4.0

- old
+ new

@@ -104,16 +104,18 @@ undo_something end end ``` -Even test group run-times -========================= +Even test group runtimes +======================== -Test groups are often not balanced and will run for different times, making everything wait for the slowest group. -Use these loggers to record test runtime and then use the recorded runtime to balance test groups more evenly. +Test groups will often run for different times, making the full test run as slow as the slowest group. +Step 1: Use these loggers (see below) to record test runtime +Step 2: Your next run will use the recorded test runtimes (use `--runtime-log <file>` if you picked a location different from below) + ### RSpec Rspec: Add to your `.rspec_parallel` (or `.rspec`) : --format progress @@ -126,13 +128,15 @@ Add to your `test_helper.rb`: ```ruby require 'parallel_tests/test/runtime_logger' if ENV['RECORD_RUNTIME'] ``` -results will be logged to tmp/parallel_runtime_test.log when `RECORD_RUNTIME` is set, +results will be logged to `tmp/parallel_runtime_test.log` when `RECORD_RUNTIME` is set, so it is not always required or overwritten. +### TODO: add instructions for other frameworks + Loggers ======= RSpec: SummaryLogger -------------------- @@ -145,11 +149,11 @@ --format ParallelTests::RSpec::SummaryLogger --out tmp/spec_summary.log RSpec: FailuresLogger ----------------------- -Produce pastable command-line snippets for each failed example. For example: +Produce pasteable command-line snippets for each failed example. For example: ```bash rspec /path/to/my_spec.rb:123 # should do something ``` @@ -157,9 +161,27 @@ --format progress --format ParallelTests::RSpec::FailuresLogger --out tmp/failing_specs.log (Not needed to retry failures, for that pass [--only-failures](https://relishapp.com/rspec/rspec-core/docs/command-line/only-failures) to rspec) + + +RSpec: VerboseLogger +----------------------- + +Prints a single line for starting and finishing each example, to see what is currently running in each process. + +``` +# PID, parallel process number, spec status, example description +[14403] [2] [STARTED] Foo foo +[14402] [1] [STARTED] Bar bar +[14402] [1] [PASSED] Bar bar +``` + +Add to `.rspec_parallel` or use as CLI flag: + + --format ParallelTests::RSpec::VerboseLogger + Cucumber: FailuresLogger ----------------------- Log failed cucumber scenarios to the specified file. The filename can be passed to cucumber, prefixed with '@' to rerun failures.