Closed robpal94 closed 6 years ago
Please provide a failing test case with what you'd expect the differ to output.
Basically it would be nice, if an exception is thrown to let the user of this library know, when two processes are not comparable. Like so:
https://github.com/robpal94/bpmn-js-differ/blob/master/test/spec/differ.js#L401
I don't quite agree with your notion of not comparable.
The diagrams are comparable:
bpmn:Definitions
level (both with the ID Definitions_1
)bpmn:Collaboration
levelBecause of this I'd rather mark the collaboration as added / removed than throwing an exception.
Proposal: We talk about the collaboration being added or removed, visually speaking:
Works when diffing process with collaboration diagrams, too:
I also thought at this while I was on my way home. This would also be a good Idea, probably better then marking two diagrams as incomparable. Is such a feature currently implemented?
The
diff
Method returns the same results, when comparing two models, that are exactly the same and two completely different models with different collaborations.Consider the following two process definitions: process1 process2
When calling the
diff()
method on both of these processes, I would not expect a result that looks like, both processes are the same (or that there are no changes). The current behavior makes it very hard to distinguish, if two compared processes are the same or if these are actually complete different processes.