tzssangglass commented on a change in pull request #2886:
URL: https://github.com/apache/apisix/pull/2886#discussion_r543495083
##########
File path: t/admin/plugins.t
##########
@@ -162,3 +162,65 @@ plugins:
}
--- no_error_log
[error]
+
+
+
+=== TEST 8: get all the attributes of all plugins
+--- config
+ location /t {
+ content_by_lua_block {
+ local json = require("toolkit.json")
+ local t = require("lib.test_admin").test
+
+ local code, message, res = t('/apisix/admin/plugins/?all=true',
+ ngx.HTTP_GET
+ )
+
+ if code >= 300 then
+ ngx.status = code
+ ngx.say(message)
+ return
+ end
+
+ res = json.decode(res)
+ ngx.say(json.encode(res))
+ }
+ }
+--- response_body eval
+qr/\{"name":"example-plugin","priority":0,"schema":\{"properties":\{"i":\{"minimum":0,"type":"number"\},"ip":\{"type":"string"\},"port":\{"type":"integer"\},"s":\{"type":"string"\},"t":\{"minItems":1,"type":"array"\}\},"required":\["i"\],"type":"object"\},"type":"other","version":0.1\}/
+--- no_error_log
+[error]
+
+
+
+=== TEST 9: confirm the plugin of auth type
Review comment:
or as you say more test cases means?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]