Class: SubPub::Matchers::SubscribeToModel
- Inherits:
-
Object
- Object
- SubPub::Matchers::SubscribeToModel
- Defined in:
- lib/sub_pub_matchers.rb
Instance Method Summary collapse
-
#initialize(expected) ⇒ SubscribeToModel
constructor
A new instance of SubscribeToModel.
- #matches?(subject) ⇒ Boolean
Constructor Details
#initialize(expected) ⇒ SubscribeToModel
Returns a new instance of SubscribeToModel.
26 27 28 |
# File 'lib/sub_pub_matchers.rb', line 26 def initialize(expected) @expected = expected end |
Instance Method Details
#matches?(subject) ⇒ Boolean
30 31 32 |
# File 'lib/sub_pub_matchers.rb', line 30 def matches?(subject) subject.model_name.should == @expected.name end |