Skip to content

Commit

Permalink
Merge pull request #2870 from ganmacs/fix-test-for-waiting-event-arrival
Browse files Browse the repository at this point in the history
wait num_events  since expect_emits number is not 1, num_events
  • Loading branch information
ganmacs committed Mar 10, 2020
2 parents 26f6e71 + 7a9828d commit 94bd90a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/plugin/test_in_tail.rb
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ def test_emit_with_read_lines_limit(data)
d = create_driver(config)
msg = 'test' * 2000 # in_tail reads 8192 bytes at once.

d.run(expect_emits: 1) do
d.run(expect_emits: num_events, timeout: 1) do
File.open("#{TMP_DIR}/tail.txt", "ab") {|f|
f.puts msg
f.puts msg
Expand Down

0 comments on commit 94bd90a

Please sign in to comment.