-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add accounts-dod support in the Java SDK (#114)
## Changes Adds support for the accounts-dod.cloud.databricks.us endpoint as an accounts endpoint in the SDK. ## Tests - [x] Unit test
- Loading branch information
Showing
2 changed files
with
29 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
databricks-sdk-java/src/test/java/com/databricks/sdk/core/DatabricksConfigTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
package com.databricks.sdk.core; | ||
|
||
import static org.junit.jupiter.api.Assertions.assertFalse; | ||
import static org.junit.jupiter.api.Assertions.assertTrue; | ||
|
||
import org.junit.jupiter.api.Test; | ||
|
||
public class DatabricksConfigTest { | ||
@Test | ||
public void testIsAccountHost() { | ||
assertTrue( | ||
new DatabricksConfig().setHost("https://accounts.azuredatabricks.net").isAccountClient()); | ||
} | ||
|
||
@Test | ||
public void testIsAccountHostDod() { | ||
assertTrue( | ||
new DatabricksConfig() | ||
.setHost("https://accounts-dod.cloud.databricks.us") | ||
.isAccountClient()); | ||
} | ||
|
||
@Test | ||
public void testIsAccountHostWorkspace() { | ||
assertFalse( | ||
new DatabricksConfig().setHost("https://westeurope.azuredatabricks.net").isAccountClient()); | ||
} | ||
} |