Fixes discovered by MS-SQL validator tests in QA-core, fixing custom ports being used (not default) and allowing the use of self signed certificates. Also updating an error message in line with Peters changes.

This commit is contained in:
mike12345567 2023-06-29 15:08:14 +01:00 committed by Adria Navarro
parent 3e62953947
commit 7b6246ee59
2 changed files with 3 additions and 2 deletions

View File

@ -186,10 +186,11 @@ class SqlServerIntegration extends Sql implements DatasourcePlus {
try {
const clientCfg: MSSQLConfig & sqlServer.config = {
...this.config,
port: +this.config,
port: +this.config.port,
options: {
encrypt: this.config.encrypt,
enableArithAbort: true,
trustServerCertificate: true,
},
}
delete clientCfg.encrypt

View File

@ -58,7 +58,7 @@ describe("datasource validators", () => {
const result = await integration.testConnection()
expect(result).toEqual({
connected: false,
error: "ConnectionError: Login failed for user 'sa'.",
error: "Login failed for user 'sa'.",
})
})
})