Skip to content

Commit

Permalink
Remove unnecessary const declaration in sys tests
Browse files Browse the repository at this point in the history
- they are only used once
  • Loading branch information
ChunyiLyu committed Sep 30, 2020
1 parent a0ba1d4 commit 206e217
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 1 addition & 6 deletions system_tests/system_tests.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,6 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

const (
statefulSetSuffix = "server"
pluginsConfig = "plugins-conf"
)

var _ = Describe("Operator", func() {
var (
namespace = MustHaveEnv("NAMESPACE")
Expand Down Expand Up @@ -127,7 +122,7 @@ var _ = Describe("Operator", func() {
})).To(Succeed())

getConfigMapAnnotations := func() map[string]string {
configMapName := cluster.ChildResourceName(pluginsConfig)
configMapName := cluster.ChildResourceName("plugins-conf")
configMap, err := clientSet.CoreV1().ConfigMaps(cluster.Namespace).Get(ctx, configMapName, metav1.GetOptions{})
Expect(err).ToNot(HaveOccurred())
return configMap.Annotations
Expand Down
2 changes: 1 addition & 1 deletion system_tests/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ func createRabbitmqCluster(ctx context.Context, client client.Client, rabbitmqCl
}

func statefulSetPodName(cluster *rabbitmqv1beta1.RabbitmqCluster, index int) string {
return cluster.ChildResourceName(strings.Join([]string{statefulSetSuffix, strconv.Itoa(index)}, "-"))
return cluster.ChildResourceName(strings.Join([]string{"server", strconv.Itoa(index)}, "-"))
}

/*
Expand Down

0 comments on commit 206e217

Please sign in to comment.