bisakhmondal commented on a change in pull request #1615:
URL: https://github.com/apache/apisix-dashboard/pull/1615#discussion_r597392430



##########
File path: api/test/e2e/server_info_delete_test.go
##########
@@ -0,0 +1,57 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package e2e
+
+import (
+       "net/http"
+       "testing"
+)
+

Review comment:
       Hii @Jaycean, thanks for the suggestion. I intentionally didn't go with 
ginkgo as it runs **independent** tests concurrently/parallelly. Going with 
ginkgo introduces a racing condition between tests if one of the tests alters 
data in the environment on which the success of other test cases largely 
depends (which is the case here, removing a node data before other tests on 
server_info runs causes a failure). It breaks the entire test suite. I have 
faced the same scenario, you could check 
[here](https://github.com/apache/apisix-dashboard/pull/1583#issuecomment-799639410).
   Still, I don't know any good hack to get around the issue. An alternative, 
not so good approach could be creating another suite for this type of scenarios 
(as we are running cleanups after each test suite) 
[ref](https://github.com/onsi/ginkgo/issues/294#issuecomment-305999281).
   
   Just for the reconfirmation. 
   
![image](https://user-images.githubusercontent.com/41498427/111729659-881c6900-8895-11eb-89e0-d5eacbbaa06f.png)
   Broke suite, haha.
   Thank you.




-- 
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:
us...@infra.apache.org


Reply via email to