integration layer; merge work on indicators from forks with existing ingestion pipeline
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import { SqlConnection, SqlQueryTable, SqlTable } from './sql-source';
|
||||
|
||||
describe('SqlConnection', () => {
|
||||
it('sends the server settings, never a hand-built URL', async () => {
|
||||
const server = { engine: 'mssql', host: 'his.local', port: null, database: 'HIS', user: 'lector', password: 'p@ss' };
|
||||
const connection = new SqlConnection({ server }, 'HIS · lector@his.local:1433', 'dbo');
|
||||
expect(await new SqlTable(connection, 'pacientes').locator()).toEqual({
|
||||
source_type: 'sql',
|
||||
payload: { server, table: 'pacientes', schema: 'dbo' },
|
||||
});
|
||||
expect(await new SqlQueryTable(connection, 'q', 'SELECT 1').locator()).toEqual({
|
||||
source_type: 'sql',
|
||||
payload: { server, query: 'SELECT 1' },
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user