diff --git a/lib/postoffice/messaging/publisher.ex b/lib/postoffice/messaging/publisher.ex index 601ee8e8..99faa02b 100644 --- a/lib/postoffice/messaging/publisher.ex +++ b/lib/postoffice/messaging/publisher.ex @@ -45,7 +45,7 @@ defmodule Postoffice.Messaging.Publisher do def calculate_chunk_size(publisher) do case publisher.chunk_size do nil -> - 1 + 100 value -> value diff --git a/test/postoffice/messaging/publisher_test.exs b/test/postoffice/messaging/publisher_test.exs index 1fd8af4b..febe6a65 100644 --- a/test/postoffice/messaging/publisher_test.exs +++ b/test/postoffice/messaging/publisher_test.exs @@ -26,11 +26,11 @@ defmodule Postoffice.Messaging.PublisherTest do assert Publisher.calculate_chunk_size(publisher) == 1 end - test "calculate_chunk_size/1 returns 1 when publisher's type is pubsub and no chunk specified" do + test "calculate_chunk_size/1 returns 100 when publisher's type is pubsub and no chunk specified" do topic = Fixtures.create_topic() publisher = Fixtures.create_publisher(topic, @pubsub_publisher_attrs) - assert Publisher.calculate_chunk_size(publisher) == 1 + assert Publisher.calculate_chunk_size(publisher) == 100 end test "calculate_chunk_size/1 returns publishers chunk_size when publisher's type is pubsub" do