Skip to content

Commit

Permalink
allow ServiceParsingError for unresponsive provider test (rare case b…
Browse files Browse the repository at this point in the history
…ut same result)
  • Loading branch information
fmigneault committed Dec 5, 2023
1 parent a39e375 commit 6936e23
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/wps_restapi/test_providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ def test_register_provider_unresponsive(self):
assert unresponsive_id in resp.json["description"]
err_msg = "Expected service to have trouble retrieving metadata, error: {} not in {}"
# different errors/causes are raised first based on requests version, but same issue
known_causes = ["Connection refused", "Connection aborted", "not accessible"]
known_errors = ["ConnectionError", "ConnectTimeout", "ReadTimeout", "SSLError"]
known_causes = ["Connection refused", "Connection aborted", "not accessible", "Unable to process"]
known_errors = ["ConnectionError", "ConnectTimeout", "ReadTimeout", "SSLError", "ServiceParsingError"]
resp_cause = resp.json["cause"]
resp_error = resp.json["error"]
assert any(err_cause in resp_cause for err_cause in known_causes), err_msg.format(resp_cause, known_causes)
Expand Down

0 comments on commit 6936e23

Please sign in to comment.