Skip to content

Commit

Permalink
fix(core): fix code
Browse files Browse the repository at this point in the history
  • Loading branch information
oowl committed Jul 11, 2024
1 parent 7d138ef commit af5f8e4
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions spec/02-integration/05-proxy/22-reports_spec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,20 @@ for _, strategy in helpers.each_strategy() do
proxy_ssl_client:close()
end)

it("when send http request to https port, no other error in error.log", function()
local https_port = assert(helpers.get_proxy_port(true))
local proxy_client = assert(helpers.proxy_client(nil, https_port))
local res = proxy_client:get("/", {
headers = { host = "http-service.test" }
})
reports_send_ping({port=constants.REPORTS.STATS_TLS_PORT})

assert.response(res).has_status(400)
assert.logfile().has.no.line("using uninitialized")
assert.logfile().has.no.line("could not determine log suffix (scheme=http, proxy_mode=)")
proxy_client:close()
end)

it("reports h2c requests", function()
local h2c_client = assert(helpers.proxy_client_h2c())
local body, headers = h2c_client({
Expand Down

0 comments on commit af5f8e4

Please sign in to comment.