leftright is kind of like the redgreen gem. It makes passing tests look green, exceptions yellow, and failures red. But then there’s more:
* It lets you know which TestCase class is being tested * It shows you the full text of failures and exceptions as they happen * It skips all remaining tests for a TestCase class if one fails
This release was tested under:
* REE 1.8.7 * MRI 1.8.6, 1.8.7 and 1.9.2 * JRuby 1.6.0 (in 1.8 mode only for now)
JRuby versions earlier than 1.6 and Rubinius are not building on my laptop right now. If you need those, please use 0.9.0 until I can figure out a better way to test these.
Right now this is pretty heavily dependent on Test::Unit. It works in both 1.8 and 1.9, but in 1.9 it is assumed you have the ‘test-unit’ gem installed and properly loaded (as opposed to the MiniTest compatibility shim).
Thanks to github.com/quirkey for Ruby 1.9 help.
gem install leftright
If you’re on JRuby, you’ll need to install ffi-ncurses to format properly:
jruby -S gem install ffi-ncurses
require 'leftright' class SomeTest < Test::Unit::TestCase def test_that_true_is_indeed_true assert_equal true, true end end
Then run the file with ruby. Mind you, it gets a lot more exciting with your own tests, specially if they fail. :)
Copyright © 2009, 2010, 2011 Jordi Bunster, released under the MIT license.