From f8b8e0fa93ca1c3c635bb77b94ad06348282287b Mon Sep 17 00:00:00 2001 From: Hector Castejon Diaz Date: Fri, 5 Jun 2026 13:25:04 +0000 Subject: [PATCH] acceptance: prefix unique test resource names with "cli" Cloud acceptance tests create real Databricks resources (SQL warehouses, clusters, schemas, ...) named from the per-run uniqueName. With a bare base32 name, these are indistinguishable from other tooling's leaked test resources in shared test workspaces, which makes attribution and cleanup hard. Prefix the unique name with "cli" so CLI-created cloud resources are identifiable. The prefix has no separator on purpose: the name feeds both bundle/project names (which allow only [a-zA-Z0-9_]) and app hostnames (which disallow underscores), so a separator-less alphanumeric prefix is the only form valid in every context. The replacement keys on the full value, so output normalization to [UNIQUE_NAME] is unchanged and no golden outputs change. Signed-off-by: Hector Castejon Diaz --- acceptance/acceptance_test.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/acceptance/acceptance_test.go b/acceptance/acceptance_test.go index 8948b31438..2fc53613c5 100644 --- a/acceptance/acceptance_test.go +++ b/acceptance/acceptance_test.go @@ -633,7 +633,14 @@ func runTest(t *testing.T, } id := uuid.New() - uniqueName := strings.ToLower(strings.Trim(base32.StdEncoding.EncodeToString(id[:]), "=")) + // Prefix the unique name so that cloud resources created by acceptance tests + // (SQL warehouses, clusters, schemas, ...) are attributable to the CLI acceptance + // suite and can be found and cleaned up in shared test workspaces. The replacement + // below keys on the full value, so output normalization to [UNIQUE_NAME] is unaffected. + // The prefix has no separator on purpose: the name feeds both bundle/project names + // (which allow only [a-zA-Z0-9_]) and app hostnames (which disallow underscores), so a + // separator-less alphanumeric prefix is the only form valid in every context. + uniqueName := "cli" + strings.ToLower(strings.Trim(base32.StdEncoding.EncodeToString(id[:]), "=")) repls.Set(uniqueName, "[UNIQUE_NAME]") var tmpDir string