mirror of
https://github.com/wxWidgets/wxWidgets.git
synced 2026-08-18 01:19:45 +08:00
Add a test exercising the IPC-over-sockets implementation from a single thread and from multiple threads concurrently (Execute, Request, Poke, Advise, combined Advise+Request, and concurrent main-thread and worker-thread Request()s). Each test starts its own server by re-executing the test program with WX_IPC_TEST_SERVER set and shuts it down again in the fixture teardown, so no server process outlives a test (or disturbs the unrelated GUI tests in test_gui). The client runs in the main Catch2 process and queries the server for state to verify it (Catch2 macros cannot run in the server process). The wait loops are wall-clock bounded so they behave under a GUI event loop, and a per-fixture watchdog aborts with a diagnostic if a test ever hangs rather than letting CI time out. The test runs in both the console "test" and the GUI "test_gui" programs. It is excluded from one configuration: wxQt, whose event loop does not reliably process a cross-thread CallAfter() (a wxQt bug fixed separately).