Skip to content

Instantly share code, notes, and snippets.

@aanand
Created May 11, 2011 17:01
Show Gist options
  • Save aanand/966868 to your computer and use it in GitHub Desktop.
Save aanand/966868 to your computer and use it in GitHub Desktop.
if RUBY_VERSION < '1.9'
require 'redgreen'
else
require 'colored'
# A poor person's redgreen.
class ActiveSupport::TestCase
def run(*args, &block)
result = super(*args, &block)
case result
when '.' then result.green
when 'F' then result.red
when 'E' then result.yellow
else result
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment