mirror of https://github.com/nocodb/nocodb
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
345 B
12 lines
345 B
2 years ago
|
const { PromisedDatabase } = require('promised-sqlite3');
|
||
|
const sqliteDb = new PromisedDatabase();
|
||
2 years ago
|
|
||
|
async function sqliteExec(query) {
|
||
2 years ago
|
const rootProjectDir = __dirname.replace('/scripts/playwright/setup', '');
|
||
2 years ago
|
await sqliteDb.open(`${rootProjectDir}/packages/nocodb/test_noco.db`);
|
||
|
|
||
|
await sqliteDb.run(query);
|
||
|
}
|
||
|
|
||
2 years ago
|
export default sqliteExec;
|