Skip to content

Commit 88e341e

Browse files
authored
ci: sync APISIX use 9180 as default port of admin API (#197)
1 parent cc0a102 commit 88e341e

File tree

5 files changed

+13
-6
lines changed

5 files changed

+13
-6
lines changed

ci/docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ services:
2828
- etcd
2929
ports:
3030
- "9080:9080/tcp"
31+
- "9180:9180/tcp"
3132
- "9091:9091/tcp"
3233
- "9443:9443/tcp"
3334
- "9092:9092/tcp"

tests/e2e/plugins/plugins_post_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ var _ = ginkgo.Describe("Post", func() {
3232
tools.RunTestCase(tc)
3333
},
3434
table.Entry("create java runner post plugin route success", tools.HttpTestCase{
35-
Object: tools.GetA6Expect(),
35+
Object: tools.PutA6Conf(),
3636
Method: http.MethodPut,
3737
Path: "/apisix/admin/routes/1",
3838
Body: `{

tests/e2e/plugins/plugins_rewrite_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ var _ = ginkgo.Describe("Stop", func() {
3131
tools.RunTestCase(tc)
3232
},
3333
table.Entry("create java runner stop plugin route success", tools.HttpTestCase{
34-
Object: tools.GetA6Expect(),
34+
Object: tools.PutA6Conf(),
3535
Method: http.MethodPut,
3636
Path: "/apisix/admin/routes/1",
3737
Body: `{

tests/e2e/plugins/plugins_stop_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ var _ = ginkgo.Describe("Stop", func() {
3232
tools.RunTestCase(tc)
3333
},
3434
table.Entry("create java runner stop plugin route success", tools.HttpTestCase{
35-
Object: tools.GetA6Expect(),
35+
Object: tools.PutA6Conf(),
3636
Method: http.MethodPut,
3737
Path: "/apisix/admin/routes/1",
3838
Body: `{

tests/e2e/tools/tools.go

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,23 @@ import (
2626
)
2727

2828
var (
29-
token = "edd1c9f034335f136f87ad84b625c8f1"
30-
A6Host = "http://127.0.0.1:9080"
29+
token = "edd1c9f034335f136f87ad84b625c8f1"
30+
A6_CP_Host = "http://127.0.0.1:9180"
31+
A6_DP_Host = "http://127.0.0.1:9080"
3132
)
3233

3334
func GetAdminToken() string {
3435
return token
3536
}
3637

38+
func PutA6Conf() *httpexpect.Expect {
39+
t := ginkgo.GinkgoT()
40+
return httpexpect.New(t, A6_CP_Host)
41+
}
42+
3743
func GetA6Expect() *httpexpect.Expect {
3844
t := ginkgo.GinkgoT()
39-
return httpexpect.New(t, A6Host)
45+
return httpexpect.New(t, A6_DP_Host)
4046
}
4147

4248
type HttpTestCase struct {

0 commit comments

Comments
 (0)