Skip to content

Commit

Permalink
fix: fixed controllers/apps/cluster_controller_test.go setup error
Browse files Browse the repository at this point in the history
  • Loading branch information
nashtsai committed Apr 22, 2023
1 parent 45b45bd commit 9145427
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions controllers/apps/cluster_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1216,7 +1216,7 @@ var _ = Describe("Cluster Controller", func() {
BeforeEach(func() {
By("Create a clusterDefinition obj")
clusterDefObj = testapps.NewClusterDefFactory(clusterDefName).
AddComponentDef(testapps.StatefulMySQLComponent, replicationCompDefName).
AddComponentDef(testapps.ReplicationRedisComponent, replicationCompDefName).
Create(&testCtx).GetObject()
})

Expand All @@ -1239,7 +1239,7 @@ var _ = Describe("Cluster Controller", func() {
clusterDefObj = testapps.NewClusterDefFactory(clusterDefName).
AddComponentDef(testapps.StatefulMySQLComponent, statefulCompDefName).
AddComponentDef(testapps.ConsensusMySQLComponent, consensusCompDefName).
AddComponentDef(testapps.StatefulMySQLComponent, replicationCompDefName).
AddComponentDef(testapps.ReplicationRedisComponent, replicationCompDefName).
AddComponentDef(testapps.StatelessNginxComponent, statelessCompDefName).
Create(&testCtx).GetObject()

Expand Down Expand Up @@ -1274,12 +1274,12 @@ var _ = Describe("Cluster Controller", func() {
BeforeEach(func() {
By("Create a clusterDefinition obj")
clusterDefObj = testapps.NewClusterDefFactory(clusterDefName).
AddComponentDef(testapps.StatefulMySQLComponent, replicationCompDefName).
AddComponentDef(testapps.StatefulMySQLComponent, statefulCompDefName).
Create(&testCtx).GetObject()

By("Create a clusterVersion obj")
clusterVersionObj = testapps.NewClusterVersionFactory(clusterVersionName, clusterDefObj.GetName()).
AddComponent(replicationCompDefName).AddContainerShort("mysql", testapps.ApeCloudMySQLImage).
AddComponent(statefulCompDefName).AddContainerShort("mysql", testapps.ApeCloudMySQLImage).
Create(&testCtx).GetObject()

By("Creating a BackupPolicyTemplate")
Expand Down Expand Up @@ -1339,12 +1339,12 @@ var _ = Describe("Cluster Controller", func() {
BeforeEach(func() {
By("Create a clusterDef obj")
clusterDefObj = testapps.NewClusterDefFactory(clusterDefName).
AddComponentDef(testapps.ConsensusMySQLComponent, replicationCompDefName).
AddComponentDef(testapps.ConsensusMySQLComponent, consensusCompDefName).
Create(&testCtx).GetObject()

By("Create a clusterVersion obj")
clusterVersionObj = testapps.NewClusterVersionFactory(clusterVersionName, clusterDefObj.GetName()).
AddComponent(replicationCompDefName).AddContainerShort("mysql", testapps.ApeCloudMySQLImage).
AddComponent(consensusCompDefName).AddContainerShort("mysql", testapps.ApeCloudMySQLImage).
Create(&testCtx).GetObject()

By("Creating a BackupPolicyTemplate")
Expand Down

0 comments on commit 9145427

Please sign in to comment.