From 00d088c13f24b9a3562c10e673722c4bef9e2dee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=98=BF=E7=94=B7?= Date: Wed, 24 Aug 2022 00:29:59 +0800 Subject: [PATCH] add todo --- test_scripts/test_upt.lua | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/test_scripts/test_upt.lua b/test_scripts/test_upt.lua index 2563655..93989f8 100644 --- a/test_scripts/test_upt.lua +++ b/test_scripts/test_upt.lua @@ -27,10 +27,13 @@ local no_exception, resp, resp_err = pcall(httpc.request_uri, httpc, remote_url, method = "GET", }) +--TODO: send resp.body to Flask API (ai-api) -> convert_mxml_to_xml() -> XML string +--local xml = ai-api.convert_mxml_to_xml(resp.body) +--ngx.say(xml) -ngx.say("RESP -> ", pl.write(resp)) ----- save the content to a file -local f = assert(io.open('test.jpg', 'wb')) -- open in "binary" mode -f:write(resp.body) --- -f:close() +--ngx.say("RESP -> ", pl.write(resp)) +------ save the content to a file +--local f = assert(io.open('test.jpg', 'wb')) -- open in "binary" mode +--f:write(resp.body) +---- +--f:close()