feat(tests): integrate qenv for dynamic configuration and enhance SKR API tests
This commit is contained in:
@@ -1,12 +1,16 @@
|
||||
import { tap, expect } from '@git.zone/tstest/tapbundle';
|
||||
import * as skr from '../ts/index.js';
|
||||
import { getTestConfig } from './helpers/setup.js';
|
||||
|
||||
let api: skr.SkrApi;
|
||||
let testConfig: Awaited<ReturnType<typeof getTestConfig>>;
|
||||
|
||||
tap.test('should initialize SKR04 API', async () => {
|
||||
testConfig = await getTestConfig();
|
||||
|
||||
api = new skr.SkrApi({
|
||||
mongoDbUrl: 'mongodb://localhost:27017',
|
||||
dbName: 'test_skr04',
|
||||
mongoDbUrl: testConfig.mongoDbUrl,
|
||||
dbName: `${testConfig.mongoDbName}_skr04`,
|
||||
});
|
||||
|
||||
await api.initialize('SKR04');
|
||||
|
Reference in New Issue
Block a user