Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
'use strict';
require('../../TestHelper');
var DOMEvents = require('table-js/test/util/DOMEvents'),
createEvent = DOMEvents.createEvent;
/* global bootstrapModeler, inject */
var basicXML = require('../../../../fixtures/dmn/literal-expression.dmn');
describe('features/literal-expression', function() {
var modeler;
beforeEach(function(done) {
modeler = bootstrapModeler(basicXML)(done);
});
it('should should show the literal expression editor', inject(function(sheet) {
expect(sheet.getContainer().querySelector('.literal-expression-editor')).to.exist;
}));
'use strict';
var TestHelper = require('../helper');
var DOMEvents = require('table-js/test/util/DOMEvents'),
mouseEvent = DOMEvents.performMouseEvent,
createEvent = DOMEvents.createEvent;
function clickElement(element, isMousedown) {
return TestHelper.getDrdJS().invoke(function(elementRegistry) {
var target = elementRegistry.getGraphics(element);
if (!target) {
target = element;
}
if (isMousedown) {
mouseEvent('mousedown', target);
} else {
mouseEvent('click', target);
}