File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change 143143 allow ( offset_manager ) . to receive ( :set_default_offset )
144144 allow ( offset_manager ) . to receive ( :mark_as_processed )
145145 allow ( offset_manager ) . to receive ( :next_offset_for ) { 42 }
146+ allow ( offset_manager ) . to receive ( :clear_offsets )
146147
147148 allow ( group ) . to receive ( :subscribe )
148149 allow ( group ) . to receive ( :group_id )
151152 allow ( group ) . to receive ( :subscribed_partitions ) { assigned_partitions }
152153 allow ( group ) . to receive ( :assigned_to? ) { false }
153154 allow ( group ) . to receive ( :assigned_to? ) . with ( 'greetings' , 0 ) { true }
155+ allow ( group ) . to receive ( :generation_id ) { 1 }
156+ allow ( group ) . to receive ( :join )
157+ allow ( group ) . to receive ( :assigned_partitions ) { [ ] }
154158
155159 allow ( heartbeat ) . to receive ( :trigger )
156160
157161 allow ( fetcher ) . to receive ( :data? ) { fetched_batches . any? }
158162 allow ( fetcher ) . to receive ( :poll ) { [ :batches , fetched_batches ] }
163+ allow ( fetcher ) . to receive ( :reset )
159164
160165 consumer . subscribe ( "greetings" )
161166 end
Original file line number Diff line number Diff line change 145145 end
146146 thread . abort_on_exception = true
147147
148+ sleep 2
148149 messages_b . each { |i | producer . produce ( i . to_s , topic : topic_b ) }
149150 producer . deliver_messages
150151
You can’t perform that action at this time.
0 commit comments