File tree 2 files changed +6
-2
lines changed
tests/integration/fixtures
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 52
52
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
53
53
ARM_CLIENT_ID : ${{ secrets.ARM_CLIENT_ID }}
54
54
ARM_TENANT_ID : ${{ secrets.ARM_TENANT_ID }}
55
- DATABRICKS_CLUSTER_ID : ${{ secrets.TEST_USER_ISOLATION_CLUSTER_ID }}
Original file line number Diff line number Diff line change @@ -12,6 +12,11 @@ def serverless_env():
12
12
os .environ .pop ('DATABRICKS_SERVERLESS_COMPUTE_ID' )
13
13
14
14
15
+ @fixture
16
+ def set_shared_cluster (monkeypatch , debug_env , env_or_skip ):
17
+ monkeypatch .setitem (debug_env , "DATABRICKS_CLUSTER_ID" , env_or_skip ("TEST_USER_ISOLATION_CLUSTER_ID" ))
18
+
19
+
15
20
@fixture
16
21
def spark_serverless_cluster_id (ws ):
17
22
# get new spark session with serverless cluster outside the actual spark fixture under test
@@ -23,7 +28,7 @@ def spark_serverless_cluster_id(ws):
23
28
spark_serverless .stop ()
24
29
25
30
26
- def test_databricks_connect (ws , spark ):
31
+ def test_databricks_connect (set_shared_cluster , ws , spark ):
27
32
rows = spark .sql ("SELECT 1" ).collect ()
28
33
assert rows [0 ][0 ] == 1
29
34
assert not is_serverless_cluster (spark , ws )
You can’t perform that action at this time.
0 commit comments