You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2021/12/02 12:20:06 UTC

[GitHub] [apisix] membphis commented on a change in pull request #5660: test(core.log): fix unit test case

membphis commented on a change in pull request #5660:
URL: https://github.com/apache/apisix/pull/5660#discussion_r760654401



##########
File path: apisix/core/log.lua
##########
@@ -15,13 +15,13 @@
 -- limitations under the License.
 --
 
-local ngx = ngx
-local ngx_log  = ngx.log
-local require  = require
-local select = select
+local ngx          = ngx

Review comment:
       It has nothing to do with test cases. pls keep the old style

##########
File path: apisix/core/log.lua
##########
@@ -109,7 +109,7 @@ local delay_tab = setmetatable({
 
         local res, err = self.func(unpack(self.args))
         if err then
-            ngx.log(ngx.WARN, "failed to exec: ", err)
+            ngx_log(ngx.ERR, "failed to exec: ", err)

Review comment:
       ditto
   
   and if we change the log level to `error`, we need to add a test case




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org