Skip to content

Commit efaa239

Browse files
authored
acc: run deployment/bind/alert locally on all clouds (#5719)
## Changes Run `acceptance/bundle/deployment/bind/alert` against the local testserver in addition to cloud (`Local = true`). No testserver changes needed — alerts-v2 create/bind/unbind and `bundle summary` are already modeled by the fake (the same support the already-local `resources/alerts/{basic,with_file}` tests rely on). The only local-vs-cloud divergence was the summary URL. `InitializeURLs` appends `?w=<workspace id>` when the host doesn't carry the ID in its subdomain — true for the local testserver (`127.0.0.1`) and aws, but not azure/gcp vanity hosts. So: - Added a repl stripping `\?[ow]=\d+` (`Order = 0`, before the global `[NUMID]` repls), matching `resources/alerts/{basic,with_file}`. - Dropped the now-unnecessary `CloudEnvs.aws = false` skip, since the repl normalizes aws too. ## Why Part of converting `Local = false` acceptance tests to local+cloud. The `?w=` isn't a testserver fidelity gap — it's correct CLI behavior driven by host shape, and ~55 existing local goldens already record `?w=[NUMID]`. Redaction keeps one golden valid across local and all clouds, and net coverage increases (local + aws/azure/gcp vs cloud-only before). ## Tests No additional tests.
1 parent e18ef74 commit efaa239

2 files changed

Lines changed: 11 additions & 6 deletions

File tree

acceptance/bundle/deployment/bind/alert/out.test.toml

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,21 @@
11
Cloud = true
2-
Local = false
2+
Local = true
33

44
# Alert tests timeout during bundle deploy (hang at file upload for 50+ minutes).
55
# Use aggressive 5-minute timeout until the issue is resolved.
66
# See: https://github.com/databricks/cli/issues/4221
77
TimeoutCloud = "5m"
88

9-
# On aws the host URL includes the workspace ID as well. Thus skipping it to keep the test simple.
10-
CloudEnvs.aws = false
11-
129
Ignore = [
1310
"databricks.yml",
1411
"alert.json",
1512
]
13+
14+
# Redact the ?[ow]=<id> workspace query param from summary URLs. The CLI appends it
15+
# whenever the host doesn't already carry the workspace ID in its subdomain, which is
16+
# the case for the local testserver (127.0.0.1) and aws hosts; azure/gcp vanity hosts
17+
# embed the ID and omit it. Stripping it lets one golden match local and all clouds.
18+
[[Repls]]
19+
Old = '\?[ow]=\d+'
20+
New = ''
21+
Order = 0

0 commit comments

Comments
 (0)