diff --git a/integration_tests/webserver/test_rest_connector.py b/integration_tests/webserver/test_rest_connector.py index 09368187..d570f179 100644 --- a/integration_tests/webserver/test_rest_connector.py +++ b/integration_tests/webserver/test_rest_connector.py @@ -236,8 +236,13 @@ class InputSchema(pw.Schema): pw.io.csv.write(sum, output_path) pw.io.csv.write(sum_dup, output_path) - with pytest.raises(OSError, match="error while attempting to bind on address"): + with pytest.raises(OSError) as exc_info: pw.run() + error_message = str(exc_info.value) + assert ( + "error while attempting to bind on address" in error_message + or "Address already in use" in error_message + ) def _test_server_two_endpoints(