(options: SetupParams)
| 25 | } |
| 26 | } |
| 27 | export async function setupMSSQL(options: SetupParams): Promise<void> { |
| 28 | const { connectionString } = options |
| 29 | const { dirname } = options |
| 30 | const schema = fs.readFileSync(path.join(dirname, 'setup.sql'), 'utf-8') |
| 31 | const config = getMSSQLConfig(connectionString) |
| 32 | |
| 33 | const connectionPool = new mssql.ConnectionPool(config) |
| 34 | const connection = await connectionPool.connect() |
| 35 | |
| 36 | await connection.query(schema) |
| 37 | await connection.close() |
| 38 | } |
nothing calls this directly
no test coverage detected