Skip to content

Commit ddaf7ca

Browse files
committed
Fix test for new Envoy error message behavior.
1 parent 1a17c85 commit ddaf7ca

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/proxy/logging/test_basics.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -381,13 +381,13 @@ def test_logs_requests_when_backend_is_down
381381
]) do
382382
response = Typhoeus.get("http://127.0.0.1:9080/#{unique_test_id}/down", log_http_options)
383383
assert_response_code(503, response)
384-
assert_match("upstream connect error or disconnect/reset before headers. retried and the latest reset reason: remote connection failure, transport failure reason: delayed connect error: 111", response.body)
384+
assert_match("upstream connect error or disconnect/reset before headers. retried and the latest reset reason: remote connection failure, transport failure reason: delayed connect error: Connection refused", response.body)
385385

386386
record = wait_for_log(response)[:hit_source]
387387
assert_equal(503, record["response_status"])
388388
assert_logs_base_fields(record, api_user)
389-
assert_equal("127.0.0.1:9450", record["api_backend_resolved_host"])
390-
assert_equal("upstream_reset_before_response_started{remote_connection_failure,delayed_connect_error:_111}", record["api_backend_response_code_details"])
389+
assert_nil(record["api_backend_resolved_host"])
390+
assert_equal("upstream_reset_before_response_started{remote_connection_failure|delayed_connect_error:_Connection_r", record["api_backend_response_code_details"])
391391
assert_equal("URX,UF", record["api_backend_response_flags"])
392392
assert_equal("cMsSf ", record["response_cache_flags"])
393393
end

0 commit comments

Comments
 (0)