diff --git a/deploy/rabbitmq/perf-test.sh b/deploy/rabbitmq/perf-test.sh new file mode 100755 index 000000000..633f03d7c --- /dev/null +++ b/deploy/rabbitmq/perf-test.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash + +set -xeu + +instance=$1 +username=$(kubectl get secret ${instance}-default-user -o jsonpath="{.data.username}" | base64 --decode) +password=$(kubectl get secret ${instance}-default-user -o jsonpath="{.data.password}" | base64 --decode) +service=${instance} +kubectl run perf-test --image=pivotalrabbitmq/perf-test -- --uri "amqp://${username}:${password}@${service}" diff --git a/e2e/src/rabbitmq_e2e.rs b/e2e/src/rabbitmq_e2e.rs index 4650b4123..91193040f 100644 --- a/e2e/src/rabbitmq_e2e.rs +++ b/e2e/src/rabbitmq_e2e.rs @@ -35,7 +35,8 @@ pub fn rabbitmq_cluster() -> String { replicas: 3 rabbitmqConfig: additionalConfig: | - log.console.level = debug + default_user = new_user + default_pass = new_pass " .to_string() } @@ -79,8 +80,8 @@ pub async fn rabbitmq_e2e_test() -> Result<(), Error> { Ok(cm) => { let data = cm.data.unwrap(); let user_config = data.get("userDefinedConfiguration.conf").unwrap(); - if !user_config.contains("default_user=new_user") - || !user_config.contains("default_pass=new_pass") + if !user_config.contains("default_user = new_user") + || !user_config.contains("default_pass = new_pass") { println!( "Configmap is not consistent with rabbitmq cluster spec. E2e test failed."