Class: RubyEventStore::RSpec::FetchUnpublishedEvents

Inherits:
Object
  • Object
show all
Defined in:
lib/ruby_event_store/rspec/fetch_unpublished_events.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#aggregateObject (readonly)

Returns the value of attribute aggregate.


16
17
18
# File 'lib/ruby_event_store/rspec/fetch_unpublished_events.rb', line 16

def aggregate
  @aggregate
end

Instance Method Details

#aggregate?Boolean

Returns:

  • (Boolean)

12
13
14
# File 'lib/ruby_event_store/rspec/fetch_unpublished_events.rb', line 12

def aggregate?
  !aggregate.nil?
end

#callObject


8
9
10
# File 'lib/ruby_event_store/rspec/fetch_unpublished_events.rb', line 8

def call
  aggregate.unpublished_events.to_a
end

#in(aggregate) ⇒ Object


4
5
6
# File 'lib/ruby_event_store/rspec/fetch_unpublished_events.rb', line 4

def in(aggregate)
  @aggregate = aggregate
end