Skip to content

Commit

Permalink
mod port
Browse files Browse the repository at this point in the history
  • Loading branch information
qicosmos committed Nov 20, 2024
1 parent 813d2d1 commit 387ca91
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_coro_http_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1562,15 +1562,15 @@ TEST_CASE("test reverse proxy websocket") {
});
server.async_start();

coro_http_server proxy_server(1, 9002);
coro_http_server proxy_server(1, 9005);
proxy_server.set_websocket_proxy_handler("/ws_echo",
{"ws://127.0.0.1:9001/ws_echo"});
proxy_server.async_start();
std::this_thread::sleep_for(200ms);

coro_http_client client{};
auto r = async_simple::coro::syncAwait(
client.connect("ws://127.0.0.1:9002/ws_echo"));
client.connect("ws://127.0.0.1:9005/ws_echo"));
CHECK(!r.net_err);
for (int i = 0; i < 10; i++) {
async_simple::coro::syncAwait(client.write_websocket("test websocket"));
Expand Down

0 comments on commit 387ca91

Please sign in to comment.