2014-07-07 15:17:41 +00:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
var Matchers = require('../../../Matchers'),
|
|
|
|
TestHelper = require('../../../TestHelper');
|
|
|
|
|
2014-08-05 06:17:22 +00:00
|
|
|
/* global bootstrapViewer, inject */
|
2014-07-07 15:17:41 +00:00
|
|
|
|
|
|
|
|
|
|
|
var fs = require('fs');
|
|
|
|
|
2014-08-01 05:16:59 +00:00
|
|
|
var Modeler = require('../../../../lib/Modeler');
|
2014-07-07 15:17:41 +00:00
|
|
|
|
2014-08-01 05:16:59 +00:00
|
|
|
var labelEditingModule = require('../../../../lib/features/label-editing'),
|
2014-07-07 15:17:41 +00:00
|
|
|
touchModule = require('diagram-js/lib/features/touch');
|
|
|
|
|
|
|
|
|
|
|
|
describe('direct editing - touch integration', function() {
|
|
|
|
|
2014-07-30 14:06:32 +00:00
|
|
|
beforeEach(Matchers.addDeepEquals);
|
2014-07-07 15:17:41 +00:00
|
|
|
|
|
|
|
|
|
|
|
var container;
|
|
|
|
|
|
|
|
beforeEach(function() {
|
|
|
|
container = jasmine.getEnv().getTestContainer();
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
function createModeler(xml, done) {
|
|
|
|
var modeler = new Modeler({ container: container });
|
|
|
|
|
|
|
|
modeler.importXML(xml, function(err) {
|
|
|
|
done(err, modeler);
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
it('should work on modeler (manual test)', function(done) {
|
|
|
|
var xml = fs.readFileSync('test/fixtures/bpmn/simple.bpmn', 'utf8');
|
|
|
|
createModeler(xml, done);
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
describe('event integration', function() {
|
|
|
|
|
|
|
|
var diagramXML = fs.readFileSync('test/fixtures/bpmn/features/label-editing/labels.bpmn', 'utf-8');
|
|
|
|
|
|
|
|
var testModules = [ labelEditingModule, touchModule ];
|
|
|
|
|
2014-08-05 06:17:22 +00:00
|
|
|
beforeEach(bootstrapViewer(diagramXML, { modules: testModules }));
|
2014-07-07 15:17:41 +00:00
|
|
|
|
|
|
|
it('should work via dbltap (manual test)', function() { });
|
|
|
|
});
|
|
|
|
|
|
|
|
});
|