Skip to content

Commit a4a1409

Browse files
Fixing flaky unit test.
1 parent d4820f7 commit a4a1409

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

test/unit/ast-editor-service.spec.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -736,7 +736,6 @@ describe('ast editor service unit tests', () => {
736736
astEditorService.eventEmitter.once('preview', (data) => {
737737
expect(data.key).to.equal('0_648_17');
738738
expect(data.preview.substring(0, 23)).to.equal('data:image/webp;base64,');
739-
done();
740739
});
741740

742741
astEditorService.importNode(pathToNodeToImport,
@@ -746,7 +745,10 @@ describe('ast editor service unit tests', () => {
746745
{
747746
'shouldCompressFile': false,
748747
'forceExtractPreview': true
749-
});
748+
})
749+
.then(() => {
750+
done();
751+
})
750752
})
751753
});
752754
});

0 commit comments

Comments
 (0)