mirror of
https://github.com/laurent22/joplin.git
synced 2024-12-21 09:38:01 +02:00
21 lines
609 B
JavaScript
21 lines
609 B
JavaScript
const { afterEachCleanUp } = require('@joplin/lib/testing/test-utils.js');
|
|
const { shimInit } = require('@joplin/lib/shim-init-node.js');
|
|
const shim = require('@joplin/lib/shim').default;
|
|
const sharp = require('sharp');
|
|
const nodeSqlite = require('sqlite3');
|
|
require('../../jest.base-setup.js')();
|
|
|
|
let keytar;
|
|
try {
|
|
keytar = shim.platformSupportsKeyChain() ? require('keytar') : null;
|
|
} catch (error) {
|
|
console.error('Cannot load keytar - keychain support will be disabled', error);
|
|
keytar = null;
|
|
}
|
|
|
|
shimInit({ sharp, keytar, nodeSqlite });
|
|
|
|
global.afterEach(async () => {
|
|
await afterEachCleanUp();
|
|
});
|