imjoey commented on a change in pull request #1218:
URL: https://github.com/apache/apisix-dashboard/pull/1218#discussion_r553723810



##########
File path: api/test/e2e/global_rule_test.go
##########
@@ -282,3 +288,108 @@ func TestGlobalRule(t *testing.T) {
                testCaseCheck(tc, t)
        }
 }
+
+func TestGlobalRule_with_createtime_updatetime(t *testing.T) {
+       tests := []HttpTestCase{
+               {
+                       Desc:   "create global rule",
+                       Object: ManagerApiExpect(t),
+                       Path:   "/apisix/admin/global_rules/1",
+                       Method: http.MethodPut,
+                       Body: `{
+                                    "plugins": {
+                                          "response-rewrite": {
+                                            "headers": {
+                                                  "X-VERSION":"1.0"
+                                                }
+                                          },
+                                          "uri-blocker": {
+                                            "block_rules": 
["select.+(from|limit)", "(?:(union(.*?)select))"]
+                                          }
+                                        }
+                                  }`,

Review comment:
       @starsz current codes 
https://github.com/apache/apisix-dashboard/blob/40d8f97de8770187599ff5963617049603020e92/api/test/e2e/global_rule_test.go#L58-L69
  mixed spaces and tabs here. So honestly, the existing style only seems good 
in GitHub pages, but not in VSCode editor. Please see the screenshot below:
   
   <img width="664" alt="image" 
src="https://user-images.githubusercontent.com/2542401/103971535-d6caca00-51a5-11eb-9130-7d8491549a89.png";>
   
   Shall we use `jq` to format the json and paste it into code? Looking forward 
to your feedback. Thanks.
   




----------------------------------------------------------------
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]


Reply via email to