mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-19 16:36:00 +00:00
test fixes
This commit is contained in:
@@ -23,6 +23,12 @@ class JsonLinesDatabase {
|
||||
await fs.writeFile(this.filename, this.data.map(x => JSON.stringify(x)).join('\n'));
|
||||
}
|
||||
|
||||
async unload() {
|
||||
this.data = [];
|
||||
this.loadedOk = false;
|
||||
this.loadPerformed = false;
|
||||
}
|
||||
|
||||
async _ensureLoaded() {
|
||||
if (!this.loadPerformed) {
|
||||
await lock.acquire('reader', async () => {
|
||||
|
||||
@@ -96,7 +96,7 @@ function packagedPluginsDir() {
|
||||
// return path.resolve(__dirname, '../../plugins');
|
||||
// }
|
||||
}
|
||||
if (processArgs.runPackerBuild) {
|
||||
if (processArgs.runE2eTests) {
|
||||
return path.resolve('packer/build/plugins');
|
||||
}
|
||||
return null;
|
||||
|
||||
@@ -14,7 +14,7 @@ const workspaceDir = getNamedArg('--workspace-dir');
|
||||
const processDisplayName = getNamedArg('--process-display-name');
|
||||
const listenApi = process.argv.includes('--listen-api');
|
||||
const listenApiChild = process.argv.includes('--listen-api-child') || listenApi;
|
||||
const runPackerBuild = process.argv.includes('--run-packer-build');
|
||||
const runE2eTests = process.argv.includes('--run-e2e-tests');
|
||||
|
||||
function getPassArgs() {
|
||||
const res = [];
|
||||
@@ -24,8 +24,8 @@ function getPassArgs() {
|
||||
if (listenApiChild) {
|
||||
res.push('listen-api-child');
|
||||
}
|
||||
if (runPackerBuild) {
|
||||
res.push('--run-packer-build');
|
||||
if (runE2eTests) {
|
||||
res.push('--run-e2e-tests');
|
||||
}
|
||||
return res;
|
||||
}
|
||||
@@ -40,5 +40,5 @@ module.exports = {
|
||||
listenApi,
|
||||
listenApiChild,
|
||||
processDisplayName,
|
||||
runPackerBuild,
|
||||
runE2eTests,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user