Skip to content

Commit 8f9b344

Browse files
committed
Cleanup after integration tests.
Running the tests repeatedly failed as the DB was left in an altered state which interfered with the subsequent test invocation. Remove the DB and generated config files after all the tests run.
1 parent 0e25b7a commit 8f9b344

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

playground/__tests__/cli.test.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@ const exec = util.promisify(require('child_process').exec);
66
jest.setTimeout(20000);
77

88
describe('Test the config-sync CLI', () => {
9+
10+
afterAll(async () => {
11+
// Remove the generated files and the DB.
12+
await exec('rm -rf config/sync');
13+
await exec('rm -rf .tmp');
14+
});
15+
916
test('Export', async () => {
1017
const { stdout } = await exec('yarn cs export -y');
1118
expect(stdout).toContain('Finished export');

0 commit comments

Comments
 (0)