lib/rimless/rspec.rb in rimless-1.0.3 vs lib/rimless/rspec.rb in rimless-1.0.4
- old
+ new
@@ -60,9 +60,13 @@
stub_request(:any, %r{^http://#{connection[:hostname]}})
.to_rack(FakeConfluentSchemaRegistryServer)
# Clear any cached data
FakeConfluentSchemaRegistryServer.clear
+ # Do not interact with Apache Kafka itself on tests
+ allow(WaterDrop::AsyncProducer).to receive(:call)
+ allow(WaterDrop::SyncProducer).to receive(:call)
+
# Reconfigure the Rimless AvroTurf instance
Rimless.configure_avro_turf
# When the example type is a Kafka consumer, we must initialize
# the Karafka framework first.