Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Backport to 1.8.7, just a matter of using ugly hash syntax.

Tested in REE 1.8.7, and tests continue to pass in MRI 1.9.2.
  • Loading branch information...
commit d099604a810cc840dce8a940fa1d01c3858af0d2 1 parent bb33676
@nathany nathany authored
View
2  README.md
@@ -12,7 +12,7 @@ Needless to say, it's a work in progress.
## Requirements
-Requires Ruby 1.9 and the gem version of minitest >= 2.0.2
+Requires Ruby 1.8.7 or 1.9 and the gem version of minitest >= 2.0.2
## Usage
View
90 lib/minitest/display.rb
@@ -23,52 +23,52 @@ module Display
class << self
def options
@options ||= {
- suite_names: true,
- suite_divider: " | ",
- suite_time: true,
- color: true,
- wrap_at: 80,
- output_slow: 5,
- print: {
- success: '.',
- failure: 'F',
- error: 'E'
+ :suite_names => true,
+ :suite_divider => " | ",
+ :suite_time => true,
+ :color => true,
+ :wrap_at => 80,
+ :output_slow => 5,
+ :print => {
+ :success => '.',
+ :failure => 'F',
+ :error => 'E'
},
- colors: {
- clear: 0,
- bold: 1,
- italics: 3,
- underline: 4,
- inverse: 9,
- strikethrough: 22,
- bold_off: 23,
- italics_off: 24,
- underline_off: 27,
- inverse_off: 29,
- strikethrough_off: 30,
- black: 30,
- red: 31,
- green: 32,
- yellow: 33,
- blue: 34,
- magenta: 35,
- cyan: 36,
- white: 37,
- default: 39,
- bg_black: 40,
- bg_red: 41,
- bg_green: 42,
- bg_yellow: 43,
- bg_blue: 44,
- bg_magenta: 45,
- bg_cyan: 46,
- bg_white: 47,
- bg_default: 49,
-
- suite: :clear,
- success: :green,
- failure: :red,
- error: :yellow
+ :colors => {
+ :clear => 0,
+ :bold => 1,
+ :italics => 3,
+ :underline => 4,
+ :inverse => 9,
+ :strikethrough => 22,
+ :bold_off => 23,
+ :italics_off => 24,
+ :underline_off => 27,
+ :inverse_off => 29,
+ :strikethrough_off => 30,
+ :black => 30,
+ :red => 31,
+ :green => 32,
+ :yellow => 33,
+ :blue => 34,
+ :magenta => 35,
+ :cyan => 36,
+ :white => 37,
+ :default => 39,
+ :bg_black => 40,
+ :bg_red => 41,
+ :bg_green => 42,
+ :bg_yellow => 43,
+ :bg_blue => 44,
+ :bg_magenta => 45,
+ :bg_cyan => 46,
+ :bg_white => 47,
+ :bg_default => 49,
+
+ :suite => :clear,
+ :success => :green,
+ :failure => :red,
+ :error => :yellow
}
}
end
View
6 test/test_minitest-display.rb
@@ -73,9 +73,9 @@ def test_equality
def test_runs_basic_test_suite_with_different_printing
capture_test_output <<-TESTCASE
MiniTest::Display.options = {
- suite_divider: ' // ',
- print: {
- success: 'PASS'
+ :suite_divider => ' // ',
+ :print => {
+ :success => 'PASS'
}
}
class PrintTest < MiniTest::Unit::TestCase
Please sign in to comment.
Something went wrong with that request. Please try again.