[ANN] test-loop 12.0.0

test-loop - Continuous testing for Ruby with fork/eval

What is it?

test-loop is a fast continuous testing tool for Ruby that automatically
detects and tests changes in your application in an efficient manner:

  1. Absorbs the test execution overhead into the main Ruby process.
  2. Forks to run your test files without overhead and in parallel.
  3. Avoids running unchanged test blocks inside changed test files.

What is new?

Incompatible changes:

  • You must now explicitly require 'test/loop/rails' for Rails
    support because we can only automatically apply our Railtie (to
    disable class caching) after the overhead has been loaded, and by
    then it’s too late: your models are already loaded & cached by the
    Rails environment.

  • Your tests can no longer read from the user’s terminal (master’s
    STDIN); instead they will read from an empty stream (the reading
    end of IO.popen).

Bug fixes:

  • Replace threads with SIGCHLD for reporting test results.

    This fixes deadlock errors that sometimes occurred when the user’s
    chosen test library tried to print something to STDOUT/STDERR
    (even though those streams were redirected to a log file in the
    worker process).

    Thanks to Brian D. Burns for suggesting and verifying that the use
    of threads to monitor workers was the culprit behind the deadlocks

  • Ctrl-C did not raise Interrupt in my Rails 3 test suite.


  • Ensure a clean ENV when reabsorbing overhead. Environment
    variables set by your test execution overhead are not propagated
    to subsequent reabsorptions. (Brian D. Burns)

  • Call setsid() to detach worker from master’s terminal.

  • Mutex is not needed since we only use GIL’ed array methods.

  • Remove redundant STDOUT coercion after loading user’s testing

  • Further simplify Test::Loop.run() by higher-order programming.


  • Add prerequisites section about POSIX environment.

  • Add tip about annihilating test-loop processes.

  • Fix markdown formatting.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs