chore(test/helper): cleanup old bpmn-js
This speeds up the test suite runs, now as the suite gets larger.
This commit is contained in:
parent
1743c63d91
commit
d87cbc3b79
|
@ -108,6 +108,11 @@ function bootstrapBpmnJS(BpmnJS, diagram, options, locals) {
|
|||
_options.additionalModules = unique(_options.additionalModules);
|
||||
}
|
||||
|
||||
// clean up old bpmn-js instance
|
||||
if (BPMN_JS) {
|
||||
BPMN_JS.destroy();
|
||||
}
|
||||
|
||||
BPMN_JS = new BpmnJS(_options);
|
||||
|
||||
BPMN_JS.importXML(diagram, done);
|
||||
|
|
Loading…
Reference in New Issue