Class: AssertFailure

Inherits:
AssertResult show all
Defined in:
lib/test_failure.rb

Overview

Assert that has failed with a message explaining why the assertion failed

Instance Attribute Summary

Attributes inherited from AssertResult

#index

Instance Method Summary collapse

Methods included from Result

#failures, #neutrals, #successes

Constructor Details

#initialize(message) ⇒ AssertFailure



45
46
47
# File 'lib/test_failure.rb', line 45

def initialize(message)
  super(message, nil)
end

Instance Method Details

#report(spacer_count) ⇒ Object



49
50
51
52
53
# File 'lib/test_failure.rb', line 49

def report(spacer_count)
  super

  Printer.fail(@spacer + format_message)
end