Skip to content

Commit

Permalink
Run go fmt on system_tests package
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcialRosales committed Nov 8, 2021
1 parent e97687d commit 88c80d9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
5 changes: 2 additions & 3 deletions system_tests/system_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ CONSOLE_LOG=new`
}
Expect(createRabbitmqCluster(ctx, rmqClusterClient, cluster)).To(Succeed())
waitForRabbitmqRunning(cluster)
waitForPortReadiness(cluster, 1883) // mqtt
waitForPortReadiness(cluster, 1883) // mqtt
waitForPortReadiness(cluster, 61613) // stomp

hostname = kubernetesNodeIp(ctx, clientSet)
Expand All @@ -594,14 +594,13 @@ CONSOLE_LOG=new`
By("Streams")
if !hasFeatureEnabled(cluster, "stream_queue") {
Skip("rabbitmq_stream plugin is not supported by RabbitMQ image " + cluster.Spec.Image)
}else {
} else {
waitForPortConnectivity(cluster)
waitForPortReadiness(cluster, 5552) // stream
publishAndConsumeStreamMsg(hostname, rabbitmqNodePort(ctx, clientSet, cluster, "stream"), username, password)
}
})


})

})
8 changes: 3 additions & 5 deletions system_tests/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@ type featureFlag struct {
State string
}



func MustHaveEnv(name string) string {
value := os.Getenv(name)
if value == "" {
Expand Down Expand Up @@ -996,8 +994,8 @@ func publishAndConsumeStreamMsg(host, port, username, password string) {
portInt, err := strconv.Atoi(port)
Expect(err).ToNot(HaveOccurred())

var env *stream.Environment
Eventually(func() error{
var env *stream.Environment
Eventually(func() error {
fmt.Println("connecting to stream endpoint ...")
env, err = stream.NewEnvironment(stream.NewEnvironmentOptions().
SetHost(host).
Expand All @@ -1011,7 +1009,7 @@ func publishAndConsumeStreamMsg(host, port, username, password string) {
if err == nil {
fmt.Println("connected to stream endpoint")
return nil
}else {
} else {
fmt.Printf("failed to connect to stream endpoint (%s:%d) due to %g\n", host, portInt, err)
}
return err
Expand Down

0 comments on commit 88c80d9

Please sign in to comment.