Skip to content

Commit

Permalink
spec: Make sure to wait server for TLS tests
Browse files Browse the repository at this point in the history
Signed-off-by: Takuro Ashie <[email protected]>
  • Loading branch information
ashie committed Mar 16, 2023
1 parent b09715e commit e44780d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions spec/fluent_logger_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,16 @@ def flush(messages)

before(:each) do
fluentd.startup(true)
# Make sure to wait TLS server since preparing it takes longer time than
# non-TLS so that it might be too early especially on CI environment
3.times do
begin
TCPSocket.open('localhost', fluentd.port) {}
break
rescue
fluentd.wait_transfer
end
end
end

after(:each) do
Expand Down

0 comments on commit e44780d

Please sign in to comment.