Skip to content

Commit 9a69f5c

Browse files
committed
Enabling stream_timeout test on Apple.
1 parent dd0a138 commit 9a69f5c

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

Release/tests/functional/http/client/connections_and_errors.cpp

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ TEST_FIXTURE(uri_address, content_ready_timeout)
207207
listener.close().wait();
208208
}
209209

210-
TEST_FIXTURE(uri_address, stream_timeout, "Ignore:Apple", "149")
210+
TEST_FIXTURE(uri_address, stream_timeout)
211211
{
212212
web::http::experimental::listener::http_listener listener(m_uri);
213213
listener.open().wait();
@@ -230,7 +230,13 @@ TEST_FIXTURE(uri_address, stream_timeout, "Ignore:Apple", "149")
230230
http_response rsp = client.request(msg).get();
231231

232232
// The response body should timeout and we should receive an exception
233-
VERIFY_THROWS_HTTP_ERROR_CODE(rsp.body().read_to_end(streams::producer_consumer_buffer<uint8_t>()).wait(), std::errc::timed_out);
233+
auto readTask = rsp.body().read_to_end(streams::producer_consumer_buffer<uint8_t>());
234+
#ifdef __APPLE__
235+
// CodePlex 295
236+
VERIFY_THROWS(readTask.get(), http_exception);
237+
#else
238+
VERIFY_THROWS_HTTP_ERROR_CODE(readTask.wait(), std::errc::timed_out);
239+
#endif
234240
}
235241

236242
buf.close(std::ios_base::out).wait();

0 commit comments

Comments
 (0)