Skip to content

Commit

Permalink
tests: Fix failing test case
Browse files Browse the repository at this point in the history
This was previously segfaulting.
See the comment/note that was added as part of this commit.

Thanks to @zyp for helping to track this down.
  • Loading branch information
Tectu committed Dec 18, 2024
1 parent a62fbdf commit 8397b98
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/test_suites/components/controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,13 @@ TEST_SUITE("controller - roundtrips")
}
}

// Note: These would technically belong into the TEST_CASE() below. However, for a currently unknown reason, these strings don't survive
// until the callbacks are invoked. This should certainly be investigated.
constexpr auto cli_agent_str = "test-cli";
constexpr auto serve_agent_str = "test-serve";

TEST_CASE("Server and client set agent strings based on user_agent")
{
constexpr auto cli_agent_str = "test-cli";
constexpr auto serve_agent_str = "test-serve";
constexpr auto addr = "127.0.0.1";
constexpr uint16_t port = 55123;

Expand Down

0 comments on commit 8397b98

Please sign in to comment.