Skip to content

Commit 803c2f3

Browse files
authored
tests: unblock CLI integration nightlies after main-branch drift (#5076)
## Why Integration test nightlies (`cli-isolated-pr.yml`) have been red on every main run since 2026-04-02, when `#4899` temporarily disabled the trigger. The trigger was re-enabled in `#5034` and all accumulated failures surfaced at once. Nothing in any in-flight feature PR is to blame; this PR just clears the backlog so nightly signal goes green again. Two independent regressions: 1. The host-metadata cache (`#5011`) regenerated goldens for tests that run locally, but could not touch `Cloud=true, Local=false` suites. `acceptance/selftest/record_cloud/{pipeline-crud,workspace-file-io}` still expected the pre-cache `/.well-known/databricks-config` calls. 2. Lakeview server behavior now varies by cloud on workspace import. AWS staging includes `serialized_dashboard` in the updated fields; GCP production no longer clears `warehouse_id`. The exact-match assertions in `TestDashboardAssumptions_WorkspaceImport` fail differently on each cloud. ## Changes **Before:** `record_cloud` goldens include redundant `/.well-known/databricks-config` GETs; dashboard test hard-codes exact updated/deleted fields. **Now:** goldens regenerated against e2-dogfood (only diff is removal of the cached requests); dashboard assertions use `assert.Subset` so they tolerate cross-cloud drift but still fail on anything outside the known-allowed set. - `acceptance/selftest/record_cloud/pipeline-crud/output.txt`, `acceptance/selftest/record_cloud/workspace-file-io/output.txt`: rerun with `-update` under `CLOUD_ENV=aws` against e2-dogfood. Both terraform and direct variants produce identical output. - `integration/assumptions/dashboard_assumptions_test.go`: `etag` and `update_time` must appear in updated fields; `serialized_dashboard` is allowed; `warehouse_id` is the only allowed deletion. Comment points to the observed cross-cloud split so the next reader knows why. Follows the pattern of the previous Lakeview-behavior-change fix in `#4640`. ## Test plan - [x] `make checks` clean - [x] `make lint` clean (0 issues) - [x] `go test ./acceptance -run 'TestAccept/selftest/record_cloud/{workspace-file-io,pipeline-crud}'` passes against e2-dogfood (both terraform and direct variants) - [x] `go test ./integration/assumptions -run TestDashboardAssumptions_WorkspaceImport` passes against e2-dogfood - [ ] cli-isolated-pr.yml integration run on this branch comes back green
1 parent 6595063 commit 803c2f3

4 files changed

Lines changed: 5 additions & 118 deletions

File tree

acceptance/selftest/record_cloud/pipeline-crud/output.txt

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,6 @@
2727
"test-pipeline-1"
2828

2929
>>> print_requests
30-
{
31-
"method": "GET",
32-
"path": "/.well-known/databricks-config"
33-
}
3430
{
3531
"method": "GET",
3632
"path": "/api/2.0/pipelines/[UUID]"
@@ -40,10 +36,6 @@
4036
>>> [CLI] pipelines update [UUID] --json @pipeline2.json
4137

4238
>>> print_requests
43-
{
44-
"method": "GET",
45-
"path": "/.well-known/databricks-config"
46-
}
4739
{
4840
"method": "PUT",
4941
"path": "/api/2.0/pipelines/[UUID]",
@@ -65,10 +57,6 @@
6557
"test-pipeline-2"
6658

6759
>>> print_requests
68-
{
69-
"method": "GET",
70-
"path": "/.well-known/databricks-config"
71-
}
7260
{
7361
"method": "GET",
7462
"path": "/api/2.0/pipelines/[UUID]"
@@ -78,10 +66,6 @@
7866
>>> [CLI] pipelines delete [UUID]
7967

8068
>>> print_requests
81-
{
82-
"method": "GET",
83-
"path": "/.well-known/databricks-config"
84-
}
8569
{
8670
"method": "DELETE",
8771
"path": "/api/2.0/pipelines/[UUID]"
@@ -94,10 +78,6 @@ Error: The specified pipeline [UUID] was not found.
9478
Exit code: 1
9579

9680
>>> print_requests
97-
{
98-
"method": "GET",
99-
"path": "/.well-known/databricks-config"
100-
}
10181
{
10282
"method": "GET",
10383
"path": "/api/2.0/pipelines/[UUID]"

acceptance/selftest/record_cloud/volume-io/output.txt

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,6 @@
2626
}
2727

2828
>>> print_requests
29-
{
30-
"method": "GET",
31-
"path": "/.well-known/databricks-config"
32-
}
3329
{
3430
"method": "GET",
3531
"path": "/api/2.1/unity-catalog/schemas/main.schema-[UNIQUE_NAME]"
@@ -42,10 +38,6 @@
4238
}
4339

4440
>>> print_requests
45-
{
46-
"method": "GET",
47-
"path": "/.well-known/databricks-config"
48-
}
4941
{
5042
"method": "POST",
5143
"path": "/api/2.1/unity-catalog/volumes",
@@ -64,10 +56,6 @@
6456
}
6557

6658
>>> print_requests
67-
{
68-
"method": "GET",
69-
"path": "/.well-known/databricks-config"
70-
}
7159
{
7260
"method": "GET",
7361
"path": "/api/2.1/unity-catalog/volumes/main.schema-[UNIQUE_NAME].volume-[UNIQUE_NAME]"
@@ -77,10 +65,6 @@
7765
./hello.txt -> dbfs:/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]/hello.txt
7866

7967
>>> print_requests
80-
{
81-
"method": "GET",
82-
"path": "/.well-known/databricks-config"
83-
}
8468
{
8569
"method": "HEAD",
8670
"path": "/api/2.0/fs/directories/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]"
@@ -102,10 +86,6 @@
10286
hello.txt
10387

10488
>>> print_requests
105-
{
106-
"method": "GET",
107-
"path": "/.well-known/databricks-config"
108-
}
10989
{
11090
"method": "GET",
11191
"path": "/api/2.0/fs/directories/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]"
@@ -114,10 +94,6 @@ hello.txt
11494
>>> [CLI] fs cat dbfs:/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]/hello.txt
11595
hello, world
11696
>>> print_requests
117-
{
118-
"method": "GET",
119-
"path": "/.well-known/databricks-config"
120-
}
12197
{
12298
"method": "GET",
12399
"path": "/api/2.0/fs/files/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]/hello.txt"
@@ -126,10 +102,6 @@ hello, world
126102
>>> [CLI] fs rm dbfs:/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]/hello.txt
127103

128104
>>> print_requests
129-
{
130-
"method": "GET",
131-
"path": "/.well-known/databricks-config"
132-
}
133105
{
134106
"method": "HEAD",
135107
"path": "/api/2.0/fs/directories/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]/hello.txt"
@@ -146,10 +118,6 @@ hello, world
146118
>>> [CLI] fs ls dbfs:/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]
147119

148120
>>> print_requests
149-
{
150-
"method": "GET",
151-
"path": "/.well-known/databricks-config"
152-
}
153121
{
154122
"method": "GET",
155123
"path": "/api/2.0/fs/directories/Volumes/main/schema-[UNIQUE_NAME]/volume-[UNIQUE_NAME]"
@@ -158,10 +126,6 @@ hello, world
158126
>>> [CLI] volumes delete main.schema-[UNIQUE_NAME].volume-[UNIQUE_NAME]
159127

160128
>>> print_requests
161-
{
162-
"method": "GET",
163-
"path": "/.well-known/databricks-config"
164-
}
165129
{
166130
"method": "DELETE",
167131
"path": "/api/2.1/unity-catalog/volumes/main.schema-[UNIQUE_NAME].volume-[UNIQUE_NAME]"
@@ -173,10 +137,6 @@ Error: Volume 'main.schema-[UNIQUE_NAME].volume-[UNIQUE_NAME]' does not exist.
173137
Exit code: 1
174138

175139
>>> print_requests
176-
{
177-
"method": "GET",
178-
"path": "/.well-known/databricks-config"
179-
}
180140
{
181141
"method": "GET",
182142
"path": "/api/2.1/unity-catalog/volumes/main.schema-[UNIQUE_NAME].volume-[UNIQUE_NAME]"
@@ -185,10 +145,6 @@ Exit code: 1
185145
>>> [CLI] schemas delete main.schema-[UNIQUE_NAME]
186146

187147
>>> print_requests
188-
{
189-
"method": "GET",
190-
"path": "/.well-known/databricks-config"
191-
}
192148
{
193149
"method": "DELETE",
194150
"path": "/api/2.1/unity-catalog/schemas/main.schema-[UNIQUE_NAME]"
@@ -200,10 +156,6 @@ Error: Schema 'main.schema-[UNIQUE_NAME]' does not exist.
200156
Exit code: 1
201157

202158
>>> print_requests
203-
{
204-
"method": "GET",
205-
"path": "/.well-known/databricks-config"
206-
}
207159
{
208160
"method": "GET",
209161
"path": "/api/2.1/unity-catalog/schemas/main.schema-[UNIQUE_NAME]"

acceptance/selftest/record_cloud/workspace-file-io/output.txt

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111
"method": "GET",
1212
"path": "/api/2.0/preview/scim/v2/Me"
1313
}
14-
{
15-
"method": "GET",
16-
"path": "/.well-known/databricks-config"
17-
}
1814
{
1915
"method": "POST",
2016
"path": "/api/2.0/workspace/mkdirs",
@@ -27,10 +23,6 @@
2723
>>> [CLI] workspace import /Users/[USERNAME]/[UNIQUE_NAME]/hello.txt --format AUTO --file ./hello.txt
2824

2925
>>> print_requests
30-
{
31-
"method": "GET",
32-
"path": "/.well-known/databricks-config"
33-
}
3426
{
3527
"method": "POST",
3628
"path": "/api/2.0/workspace/import",
@@ -49,10 +41,6 @@
4941
}
5042

5143
>>> print_requests
52-
{
53-
"method": "GET",
54-
"path": "/.well-known/databricks-config"
55-
}
5644
{
5745
"method": "GET",
5846
"path": "/api/2.0/workspace/list",
@@ -69,10 +57,6 @@
6957
}
7058

7159
>>> print_requests
72-
{
73-
"method": "GET",
74-
"path": "/.well-known/databricks-config"
75-
}
7660
{
7761
"method": "GET",
7862
"path": "/api/2.0/workspace/get-status",
@@ -88,10 +72,6 @@
8872
hello, world
8973

9074
>>> print_requests
91-
{
92-
"method": "GET",
93-
"path": "/.well-known/databricks-config"
94-
}
9575
{
9676
"method": "GET",
9777
"path": "/api/2.0/workspace/export",
@@ -105,10 +85,6 @@ hello, world
10585
>>> [CLI] workspace delete /Users/[USERNAME]/[UNIQUE_NAME]/hello.txt
10686

10787
>>> print_requests
108-
{
109-
"method": "GET",
110-
"path": "/.well-known/databricks-config"
111-
}
11288
{
11389
"method": "POST",
11490
"path": "/api/2.0/workspace/delete",
@@ -124,10 +100,6 @@ Error: Path (/Users/[USERNAME]/[UNIQUE_NAME]/hello.txt) doesn't exist.
124100
Exit code: 1
125101

126102
>>> print_requests
127-
{
128-
"method": "GET",
129-
"path": "/.well-known/databricks-config"
130-
}
131103
{
132104
"method": "GET",
133105
"path": "/api/2.0/workspace/get-status",
@@ -144,21 +116,13 @@ ID Type Language Path
144116
>>> [CLI] workspace delete /Users/[USERNAME]/[UNIQUE_NAME]
145117

146118
>>> print_requests
147-
{
148-
"method": "GET",
149-
"path": "/.well-known/databricks-config"
150-
}
151119
{
152120
"method": "GET",
153121
"path": "/api/2.0/workspace/list",
154122
"q": {
155123
"path": "/Users/[USERNAME]/[UNIQUE_NAME]"
156124
}
157125
}
158-
{
159-
"method": "GET",
160-
"path": "/.well-known/databricks-config"
161-
}
162126
{
163127
"method": "POST",
164128
"path": "/api/2.0/workspace/delete",
@@ -174,10 +138,6 @@ Error: Path (/Users/[USERNAME]/[UNIQUE_NAME]) doesn't exist.
174138
Exit code: 1
175139

176140
>>> print_requests
177-
{
178-
"method": "GET",
179-
"path": "/.well-known/databricks-config"
180-
}
181141
{
182142
"method": "GET",
183143
"path": "/api/2.0/workspace/list",

integration/assumptions/dashboard_assumptions_test.go

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -111,15 +111,10 @@ func TestDashboardAssumptions_WorkspaceImport(t *testing.T) {
111111
})
112112
require.NoError(t, err)
113113

114-
// Confirm that only the expected fields have been updated.
115-
assert.ElementsMatch(t, []string{
116-
"etag",
117-
"update_time",
118-
}, updatedFieldPaths)
119-
120-
// The warehouse_id field is cleared after workspace import.
121-
assert.ElementsMatch(t, []string{
122-
"warehouse_id",
123-
}, deletedFieldPaths)
114+
// etag and update_time always change after workspace import. serialized_dashboard and
115+
// warehouse_id vary by Lakeview server version: observed on AWS staging but not GCP prod.
116+
assert.Subset(t, updatedFieldPaths, []string{"etag", "update_time"})
117+
assert.Subset(t, []string{"etag", "update_time", "serialized_dashboard"}, updatedFieldPaths)
118+
assert.Subset(t, []string{"warehouse_id"}, deletedFieldPaths)
124119
}
125120
}

0 commit comments

Comments
 (0)