class Stenotype::Test::Matchers::DiffSizeMatchesExpectation

Attributes

expected_count[R]
matching_events[R]

Public Class Methods

new(matching_events, expected_count) click to toggle source
# File lib/stenotype/test/matchers.rb, line 12
def initialize(matching_events, expected_count)
  @matching_events = matching_events
  @expected_count = expected_count
end

Public Instance Methods

failure_message() click to toggle source
# File lib/stenotype/test/matchers.rb, line 17
def failure_message
  "expected to see #{expected_count} event(s) but got #{matching_events.count} event(s)."
end
matches?() click to toggle source
# File lib/stenotype/test/matchers.rb, line 21
def matches?
  matching_events.count == expected_count
end