class RSpec::Core::Notifications::PendingExampleFailedAsExpectedNotification

The `PendingExampleFailedAsExpectedNotification` extends `FailedExampleNotification` with things useful for pending specs that fail as expected.

@attr [RSpec::Core::Example] example the current example @see ExampleNotification

Public Instance Methods

exception() click to toggle source

@return [Exception] The exception that occurred while the pending example was executed

# File lib/rspec/core/notifications.rb, line 339
def exception
  example.execution_result.pending_exception
end
fully_formatted(pending_number, colorizer=::RSpec::Core::Formatters::ConsoleCodes) click to toggle source

@return [String] The pending detail fully formatted in the way that

RSpec's built-in formatters emit.
# File lib/rspec/core/notifications.rb, line 345
def fully_formatted(pending_number, colorizer=::RSpec::Core::Formatters::ConsoleCodes)
  fully_formatted_header(pending_number, colorizer) << formatted_message_and_backtrace(colorizer)
end

Private Instance Methods

message_color() click to toggle source
# File lib/rspec/core/notifications.rb, line 351
def message_color
  RSpec.configuration.pending_color
end