From 1379181c62a3dc07de602e867e3e9e014c7d4a8a Mon Sep 17 00:00:00 2001 From: drivebyer Date: Tue, 14 Jan 2025 15:15:36 +0800 Subject: [PATCH] ha Signed-off-by: drivebyer --- .../v1beta2/setup/ha/chainsaw-test.yaml | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/tests/e2e-chainsaw/v1beta2/setup/ha/chainsaw-test.yaml b/tests/e2e-chainsaw/v1beta2/setup/ha/chainsaw-test.yaml index 2e4ee24e5..e81d4c3da 100644 --- a/tests/e2e-chainsaw/v1beta2/setup/ha/chainsaw-test.yaml +++ b/tests/e2e-chainsaw/v1beta2/setup/ha/chainsaw-test.yaml @@ -15,6 +15,18 @@ spec: - try: - apply: file: ha.yaml + - apply: + file: ../../../../data-assert/resources.yaml + + - name: Put data + try: + - script: + timeout: 30s + content: > + kubectl exec --namespace ${NAMESPACE} --container data-assert data-assert -- + bash -c "cd /go/src/data-assert && go run main.go gen-redis-data --host redis-sentinel-sentinel.${NAMESPACE}.svc.cluster.local:26379 --mode sentinel" + check: + (contains($stdout, 'OK')): true - name: Test Master IP consistency try: @@ -41,6 +53,16 @@ spec: - sleep: duration: 120s + - name: Assert data + try: + - script: + timeout: 30s + content: > + kubectl exec --namespace ${NAMESPACE} --container data-assert data-assert -- + bash -c "cd /go/src/data-assert && go run main.go chk-redis-data --host redis-sentinel-sentinel.${NAMESPACE}.svc.cluster.local:26379 --mode sentinel" + check: + (contains($stdout, 'OK')): true + - name: Test Master IP consistency try: - script: