Skip to content

Commit b6bdd51

Browse files
sdebruynclaude
andcommitted
Use FabricSparkCredentials with database field for lakehouse
The remote orchestrator is a DE context — use FabricSparkCredentials where database = lakehouse name (matching how FabricSpark profiles work) instead of FabricCredentials with a separate lakehouse field. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 73e5490 commit b6bdd51

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

tests/spark_remote/orchestrator.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@
55
from pathlib import Path
66

77
from dbt.adapters.fabric.fabric_api_client import FabricApiClient
8-
from dbt.adapters.fabric.fabric_credentials import FabricCredentials
98
from dbt.adapters.fabric.fabric_token_provider import FabricTokenProvider
9+
from dbt.adapters.fabricspark.fabricspark_credentials import (
10+
FabricSparkCredentials,
11+
)
1012
from tests.conftest import _auth_kwargs_from_env
1113
from tests.spark_remote.spark_job_client import SparkJobClient, SparkJobResult
1214
from tests.spark_remote.sync import ProjectSync, check_prerequisites
@@ -34,12 +36,11 @@ def from_env(cls) -> RemoteTestOrchestrator:
3436

3537
job_name = os.environ.get("FABRIC_TEST_SPARK_JOB_NAME", "dbt-fabric-tests")
3638

37-
creds = FabricCredentials(
38-
database="",
39+
creds = FabricSparkCredentials(
40+
database=os.getenv("FABRIC_TEST_LAKEHOUSE_NAME", ""),
3941
schema="dbo",
4042
workspace_name=os.getenv("FABRIC_TEST_WORKSPACE_NAME"),
4143
workspace_id=os.getenv("FABRIC_TEST_WORKSPACE_ID"),
42-
lakehouse=os.getenv("FABRIC_TEST_LAKEHOUSE_NAME"),
4344
**_auth_kwargs_from_env(),
4445
)
4546
token_provider = FabricTokenProvider(creds)

0 commit comments

Comments
 (0)