From 638615ae09ec2d311e82d89ea7a78137911f4eb4 Mon Sep 17 00:00:00 2001 From: Igor Bernstein Date: Thu, 7 Nov 2019 10:17:12 -0500 Subject: [PATCH] fix: Prevent integration tests from different profiles from trampling each other (#69) --- google-cloud-bigtable/pom.xml | 28 +++------------------------- scripts/setup-test-table.sh | 10 ++-------- 2 files changed, 5 insertions(+), 33 deletions(-) diff --git a/google-cloud-bigtable/pom.xml b/google-cloud-bigtable/pom.xml index 0587b49650..503f346b5c 100644 --- a/google-cloud-bigtable/pom.xml +++ b/google-cloud-bigtable/pom.xml @@ -220,6 +220,7 @@ com.google.cloud.bigtable.**.it.*IT ${project.build.directory}/failsafe-reports/failsafe-summary-emulator-it.xml + ${project.build.directory}/failsafe-reports/emulator-it @@ -249,6 +250,7 @@ com.google.cloud.bigtable.**.it.*IT ${project.build.directory}/failsafe-reports/failsafe-summary-prod-it.xml + ${project.build.directory}/failsafe-reports/prod-it @@ -290,6 +292,7 @@ com.google.cloud.bigtable.data.v2.it.*IT ${project.build.directory}/failsafe-reports/failsafe-summary-directpath-it.xml + ${project.build.directory}/failsafe-reports/directpath-it @@ -332,31 +335,6 @@ - - - maven-clean-plugin - 2.5 - - - clean-old-reports - - clean - - pre-integration-test - - true - - - ${project.build.directory}/failsafe-reports - - - - - - - org.apache.maven.plugins maven-failsafe-plugin diff --git a/scripts/setup-test-table.sh b/scripts/setup-test-table.sh index 6321c1154c..c8bb1e2a62 100755 --- a/scripts/setup-test-table.sh +++ b/scripts/setup-test-table.sh @@ -36,13 +36,7 @@ for ADMIN_HOST in "${ADMIN_HOSTS[@]}"; do fi # Ensure that the table exists - if ! call_cbt -instance ${INSTANCE_ID} ls | grep -q "^${TABLE_ID}\$"; then - call_cbt createtable ${TABLE_ID} - fi - - # Ensure that the family exists - if ! call_cbt ls "${TABLE_ID}" | grep -q "^$FAMILY\b"; then - call_cbt createfamily "${TABLE_ID}" "${FAMILY}" - call_cbt setgcpolicy "${TABLE_ID}" "${FAMILY}" maxversions=1 maxage=1h + if ! call_cbt -instance "$INSTANCE_ID" ls | grep -q "^${TABLE_ID}\$"; then + call_cbt createtable "$TABLE_ID" "families=$FAMILY:maxversions=1||maxage=1h" fi done