Skip to content

Commit

Permalink
move message to appropriate assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
cole committed Oct 1, 2024
1 parent 6624f5c commit d2c9e90
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -314,8 +314,7 @@ private boolean isDatabasePrincipal(Client localQueryClient) {
try {
result = localQueryClient.executeMgmt(DB_NAME, String.format(".show database %s principals", DB_NAME));
} catch (Exception ex) {
Assertions.fail("Failed to execute show database principals command. " +
"Is USERNAME_HINT set to your email in your environment variables?", ex);
Assertions.fail("Failed to execute show database principals command.", ex);
}
return resultContainsPrincipal(result);
}
Expand Down Expand Up @@ -448,14 +447,14 @@ private void assertUrlCompare(String connectionDataSource, String clusterUrl, bo
void testCreateWithUserPrompt() {
Assumptions.assumeTrue(isManualExecution());
ConnectionStringBuilder engineCsb = ConnectionStringBuilder.createWithUserPrompt(ENG_CONN_STR, null, UNAME_HINT);
assertTrue(canAuthenticate(engineCsb));
assertTrue(canAuthenticate(engineCsb), "Is USERNAME_HINT set to your email in your environment variables?");
}

@Test
void testCreateWithConnectionStringAndUserPrompt() {
Assumptions.assumeTrue(isManualExecution());
ConnectionStringBuilder engineCsb = new ConnectionStringBuilder("Data Source=" + ENG_CONN_STR + ";User ID=" + UNAME_HINT);
assertTrue(canAuthenticate(engineCsb));
assertTrue(canAuthenticate(engineCsb), "Is USERNAME_HINT set to your email in your environment variables?");
}

@Test
Expand Down

0 comments on commit d2c9e90

Please sign in to comment.