spec/rdkafka/admin_spec.rb in karafka-rdkafka-0.17.2 vs spec/rdkafka/admin_spec.rb in karafka-rdkafka-0.17.3
- old
+ new
@@ -735,6 +735,20 @@
)
expect(response).to eq(0)
end
end
end
+
+ context "when operating from a fork" do
+ # @see https://github.com/ffi/ffi/issues/1114
+ it 'expect to be able to create topics and run other admin operations without hanging' do
+ # If the FFI issue is not mitigated, this will hang forever
+ pid = fork do
+ admin
+ .create_topic(topic_name, topic_partition_count, topic_replication_factor)
+ .wait
+ end
+
+ Process.wait(pid)
+ end
+ end
end