Skip to content

Commit

Permalink
chore: rename all v2beta3 to v2 in e2e templates (#1832)
Browse files Browse the repository at this point in the history
Signed-off-by: Jintao Zhang <zhangjintao9020@gmail.com>
  • Loading branch information
tao12345666333 authored May 16, 2023
1 parent 7b81a8b commit 113defc
Show file tree
Hide file tree
Showing 48 changed files with 185 additions and 185 deletions.
2 changes: 1 addition & 1 deletion test/e2e/scaffold/upstream_tls.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (

var (
_apisixUpstreamsWithMTLSTemplate = `
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/suite-annotations/plugin_conifg.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (

func _createAPC(s *scaffold.Scaffold) {
apc := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixPluginConfig
metadata:
name: echo-and-cors-apc
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/suite-chore/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ data:
kubernetes:
namespace_selector:
- %s
apisix_route_version: "apisix.apache.org/v2beta3"
apisix_route_version: "apisix.apache.org/v2"
watch_endpoint_slices: true
`
)
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/suite-chore/consistency.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (

var (
_routeConfig = `
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
6 changes: 3 additions & 3 deletions test/e2e/suite-chore/endpoints.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ var _ = ginkgo.Describe("suite-chore: endpoints", func() {
ginkgo.It("ignore applied only if there is an ApisixRoute referenced", func() {
backendSvc, backendSvcPort := s.DefaultHTTPBackend()
ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand All @@ -56,7 +56,7 @@ spec:
ginkgo.It("upstream nodes should be reset to empty when Service/Endpoints was deleted", func() {
backendSvc, backendSvcPort := s.DefaultHTTPBackend()
apisixRoute := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -85,7 +85,7 @@ spec:
ginkgo.It("when endpoint is 0, upstream nodes is also 0", func() {
backendSvc, backendSvcPort := s.DefaultHTTPBackend()
apisixRoute := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/suite-cluster/apisix_cluster_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ var _ = ginkgo.Describe("suite-cluster: ApisixClusterConfig v2", func() {
time.Sleep(3 * time.Second)

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: default
Expand Down
8 changes: 4 additions & 4 deletions test/e2e/suite-features/healthcheck.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ var _ = ginkgo.Describe("suite-features: health check", func() {
backendSvc, backendPorts := s.DefaultHTTPBackend()

au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -51,7 +51,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), err, "create ApisixUpstream")

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -88,7 +88,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -113,7 +113,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), err, "create ApisixUpstream")

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
4 changes: 2 additions & 2 deletions test/e2e/suite-features/remote_addrs_match.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ var _ = ginkgo.Describe("suite-features: traffic split", func() {
ginkgo.It("sanity", func() {
backendSvc, backendPorts := s.DefaultHTTPBackend()
ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -60,7 +60,7 @@ spec:
resp.Body().Contains("404 Route Not Found")

ar = fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
12 changes: 6 additions & 6 deletions test/e2e/suite-features/retries.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ var _ = ginkgo.Describe("suite-features: retries", func() {
s := scaffoldFunc()

routeTpl := `
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand All @@ -53,7 +53,7 @@ spec:
time.Sleep(5 * time.Second)

au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -77,7 +77,7 @@ spec:
time.Sleep(5 * time.Second)

au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -102,7 +102,7 @@ spec:
time.Sleep(5 * time.Second)

au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand Down Expand Up @@ -132,7 +132,7 @@ var _ = ginkgo.Describe("suite-features: retries timeout", func() {
backendSvc, backendPorts := s.DefaultHTTPBackend()

au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -146,7 +146,7 @@ spec:
time.Sleep(2 * time.Second)

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
22 changes: 11 additions & 11 deletions test/e2e/suite-features/route_match_exprs.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ var _ = ginkgo.Describe("suite-features: route match exprs", func() {
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -83,7 +83,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -132,7 +132,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -256,7 +256,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -380,7 +380,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -438,7 +438,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -495,7 +495,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -554,7 +554,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -612,7 +612,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -671,7 +671,7 @@ spec:
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -737,7 +737,7 @@ var _ = ginkgo.Describe("suite-features: route match exprs bugfixes", func() {
backendSvc, backendPorts := s.DefaultHTTPBackend()

ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
8 changes: 4 additions & 4 deletions test/e2e/suite-features/scheme.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ spec:
`)
assert.Nil(ginkgo.GinkgoT(), err)
assert.Nil(ginkgo.GinkgoT(), s.CreateVersionedApisixResource(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: grpc-server-service
Expand All @@ -68,7 +68,7 @@ spec:
scheme: grpc
`))
err = s.CreateVersionedApisixResource(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: grpc-route
Expand Down Expand Up @@ -130,7 +130,7 @@ spec:
assert.NoError(ginkgo.GinkgoT(), err, "create server cert secret")

assert.NoError(ginkgo.GinkgoT(), s.CreateVersionedApisixResource(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: test-backend-service-e2e-test
Expand All @@ -139,7 +139,7 @@ spec:
`))

assert.NoError(ginkgo.GinkgoT(), s.CreateVersionedApisixResource(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: grpcs-route
Expand Down
10 changes: 5 additions & 5 deletions test/e2e/suite-features/subset.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ var _ = ginkgo.Describe("suite-features: service subset", func() {
assert.Nil(ginkgo.GinkgoT(), s.WaitAllHTTPBINPodsAvailable(), "waiting for all httpbin pods ready")
backendSvc, backendSvcPort := s.DefaultHTTPBackend()
ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -67,7 +67,7 @@ spec:
ginkgo.It("subset with bad labels", func() {
backendSvc, backendSvcPort := s.DefaultHTTPBackend()
au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -82,7 +82,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), err, "create ApisixUpstream")
time.Sleep(1 * time.Second)
ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down Expand Up @@ -119,7 +119,7 @@ spec:

backendSvc, backendSvcPort := s.DefaultHTTPBackend()
au := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixUpstream
metadata:
name: %s
Expand All @@ -133,7 +133,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), err, "create ApisixUpstream")
time.Sleep(1 * time.Second)
ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand Down
8 changes: 4 additions & 4 deletions test/e2e/suite-features/sync-comparison.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ var _ = ginkgo.Describe("suite-features: sync comparison", func() {
ginkgo.It("check resource request count", func() {
backendSvc, backendSvcPort := s.DefaultHTTPBackend()
ar := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-route
Expand All @@ -54,7 +54,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), err, "checking number of upstreams")

arStream := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: httpbin-tcp-route
Expand All @@ -80,7 +80,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), err, "create ApisixTls 'a' error")

ac := `
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixConsumer
metadata:
name: foo
Expand All @@ -107,7 +107,7 @@ spec:
assert.Nil(ginkgo.GinkgoT(), s.CreateResourceFromString(agr), "create ApisixGlobalRule")

apc := fmt.Sprintf(`
apiVersion: apisix.apache.org/v2beta3
apiVersion: apisix.apache.org/v2
kind: ApisixPluginConfig
metadata:
name: test-apc-1
Expand Down
Loading

0 comments on commit 113defc

Please sign in to comment.