Skip to content

Commit

Permalink
Fix some racy tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mtrudel committed Nov 24, 2023
1 parent 4a85aac commit 4b46024
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/thousand_island/server_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -375,6 +375,8 @@ defmodule ThousandIsland.ServerTest do
cacertfile: Path.join(__DIR__, "../support/ca.pem")
)

Process.sleep(100)

ThousandIsland.stop(server_pid)

assert_received {:options, {:certfile, _, _}}
Expand Down Expand Up @@ -407,6 +409,9 @@ defmodule ThousandIsland.ServerTest do
]
)

# Negotiation failures seem to take longer
Process.sleep(500)

ThousandIsland.stop(server_pid)

assert_received {:tls_alert, {:insufficient_security, _}}
Expand Down

0 comments on commit 4b46024

Please sign in to comment.