diff --git a/src/test/java/com/microsoft/sqlserver/jdbc/TestResource.java b/src/test/java/com/microsoft/sqlserver/jdbc/TestResource.java index 75c850fe6f..f0198d85b9 100644 --- a/src/test/java/com/microsoft/sqlserver/jdbc/TestResource.java +++ b/src/test/java/com/microsoft/sqlserver/jdbc/TestResource.java @@ -195,6 +195,5 @@ protected Object[][] getContents() { {"R_socketClosed", "Socket closed"}, {"R_aeStreamReadError", "The multi-part identifier"}, {"R_dataClassificationNotSupported", "Data Classification is not supported on this server."}, {"R_maxResultBufferExceeded", "MaxResultBuffer exceeded {0}."}, - {"R_noAuthorizationCode", "No Authorization code was returned from the server"}, {"R_databaseNotFound", "Database {0} not found."}}; } diff --git a/src/test/java/com/microsoft/sqlserver/jdbc/fedauth/ErrorMessageTest.java b/src/test/java/com/microsoft/sqlserver/jdbc/fedauth/ErrorMessageTest.java index ce92d69164..0f39c17f7a 100644 --- a/src/test/java/com/microsoft/sqlserver/jdbc/fedauth/ErrorMessageTest.java +++ b/src/test/java/com/microsoft/sqlserver/jdbc/fedauth/ErrorMessageTest.java @@ -17,10 +17,8 @@ import org.junit.platform.runner.JUnitPlatform; import org.junit.runner.RunWith; -import com.microsoft.sqlserver.jdbc.SQLServerConnectionTest; import com.microsoft.sqlserver.jdbc.SQLServerDataSource; import com.microsoft.sqlserver.jdbc.SQLServerException; -import com.microsoft.sqlserver.jdbc.TestResource; import com.microsoft.sqlserver.testframework.Constants; @@ -837,11 +835,8 @@ public void testInteractiveAuthTimeout() throws SQLException { fail(EXPECTED_EXCEPTION_NOT_THROWN); } assertTrue(INVALID_EXCEPTION_MSG + ": " + e.getMessage() + "," + e.getCause(), - e.getMessage() - .contains(ERR_MSG_FAILED_AUTHENTICATE + " the user " + azureUserName - + " in Active Directory (Authentication=ActiveDirectoryInteractive).") - && (isWindows ? e.getCause().getMessage() - .contains(TestResource.getResource("R_noAuthorizationCode")) : true)); + e.getMessage().contains(ERR_MSG_FAILED_AUTHENTICATE + " the user " + azureUserName + + " in Active Directory (Authentication=ActiveDirectoryInteractive).")); } } }