From e35248c5fd37f44fdaf5c8a9b29f2cfbfb5267fe Mon Sep 17 00:00:00 2001 From: Philipp Fromme Date: Mon, 5 Dec 2016 13:20:15 +0100 Subject: [PATCH] test(draw): add skipped test for color rendering --- lib/draw/BpmnRenderer.js | 4 +- test/fixtures/bpmn/draw/colors.bpmn | 356 ++++++++++++++++++++++++++++ test/spec/draw/BpmnRendererSpec.js | 6 + 3 files changed, 364 insertions(+), 2 deletions(-) create mode 100644 test/fixtures/bpmn/draw/colors.bpmn diff --git a/lib/draw/BpmnRenderer.js b/lib/draw/BpmnRenderer.js index c3ce36ba..cf516b62 100644 --- a/lib/draw/BpmnRenderer.js +++ b/lib/draw/BpmnRenderer.js @@ -923,8 +923,8 @@ function BpmnRenderer(eventBus, styles, pathMap, canvas, priority) { /* send path */ drawPath(parentGfx, pathData, { strokeWidth: 1, - fill: 'black', - stroke: 'white' + fill: getStrokeColor(element), + stroke: getFillColor(element) }); return task; diff --git a/test/fixtures/bpmn/draw/colors.bpmn b/test/fixtures/bpmn/draw/colors.bpmn new file mode 100644 index 00000000..ef2adc1b --- /dev/null +++ b/test/fixtures/bpmn/draw/colors.bpmn @@ -0,0 +1,356 @@ + + + + + + + + SequenceFlow_1jrsqqc + + + + SequenceFlow_1jrsqqc + SequenceFlow_0h9s0mp + + + + SequenceFlow_0h9s0mp + SequenceFlow_0pqo7zt + SequenceFlow_1qt82pt + + + + SequenceFlow_0pqo7zt + SequenceFlow_152w54z + + + + SequenceFlow_1qt82pt + SequenceFlow_17ohrlh + + + + SequenceFlow_17ohrlh + + + + SequenceFlow_152w54z + SequenceFlow_1xvnonz + + + + + SequenceFlow_1xvnonz + SequenceFlow_0mbw4et + SequenceFlow_024djlt + SequenceFlow_02klp91 + + + SequenceFlow_0mbw4et + SequenceFlow_01w8xpk + + + + + SequenceFlow_01w8xpk + SequenceFlow_17fk7n7 + + + + SequenceFlow_17fk7n7 + SequenceFlow_1hytpfi + SequenceFlow_17yh2em + + + + SequenceFlow_1hytpfi + SequenceFlow_1u8uz5a + + + + SequenceFlow_1u8uz5a + + + + SequenceFlow_024djlt + SequenceFlow_096z65r + + + + + SequenceFlow_096z65r + SequenceFlow_17yh2em + SequenceFlow_0ld619c + + + + + SequenceFlow_0ld619c + + + + SequenceFlow_02klp91 + SequenceFlow_0rng9d2 + + + + + SequenceFlow_0rng9d2 + SequenceFlow_0krol9j + + + + SequenceFlow_0krol9j + SequenceFlow_1h7edo4 + + + + SequenceFlow_1h7edo4 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/spec/draw/BpmnRendererSpec.js b/test/spec/draw/BpmnRendererSpec.js index aec9ec83..6436512a 100644 --- a/test/spec/draw/BpmnRendererSpec.js +++ b/test/spec/draw/BpmnRendererSpec.js @@ -169,6 +169,12 @@ describe('draw - bpmn renderer', function() { }); + it.skip('should render colors', function(done) { + var xml = require('../../fixtures/bpmn/draw/colors.bpmn'); + bootstrapViewer(xml)(checkErrors(done)); + }); + + it('should render call activity', function(done) { var xml = require('../../fixtures/bpmn/draw/call-activity.bpmn');