nested exit test
This commit is contained in:
@@ -17,5 +17,9 @@ server {
|
||||
location /api/ngx/test/uri {
|
||||
content_by_lua_file $resty_loc/nginx/scripts/tests/uri.lua;
|
||||
}
|
||||
|
||||
location /api/ngx/test/nested_exit {
|
||||
content_by_lua_file $resty_loc/nginx/scripts/tests/nested_exit.lua;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
local function nested_e()
|
||||
ngx.exit(ngx.HTTP_INTERNAL_SERVER_ERROR)
|
||||
end
|
||||
|
||||
nested_e()
|
||||
ngx.say("OK")
|
||||
|
||||
-- ➤ curl test.localhost:8088/api/ngx/test/nested_exit
|
||||
|
||||
|
||||
Reference in New Issue
Block a user