Make webrequest native handle test independent

Check the web session native handle only after starting the request, as the
macOS URLSession backend creates the native session lazily.

This avoids depending on prior tests having initialized shared process state.
This commit is contained in:
Richard
2026-08-17 22:51:53 -06:00
parent 0dc27e6a3f
commit 8d11bad7a3
+1 -1
View File
@@ -493,10 +493,10 @@ TEST_CASE_METHOD(RequestFixture,
Create("status/200");
CHECK( request.IsOk() );
CHECK( session.GetNativeHandle() );
// Note that the request must be started to have a valid native handle.
request.Start();
CHECK( session.GetNativeHandle() );
CHECK( request.GetNativeHandle() );
RunLoopWithTimeout();
CHECK( request.GetState() == wxWebRequest::State_Completed );