mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-18 14:59:53 +02:00
#834 Adding unit tests and rendering tests
This commit is contained in:
@@ -228,6 +228,14 @@ describe('when parsing subgraphs', function() {
|
||||
const vert = flow.parser.yy.getVertices();
|
||||
const edges = flow.parser.yy.getEdges();
|
||||
|
||||
expect(edges[0].type).toBe('arrow');
|
||||
});
|
||||
it('should handle subgraphs with multi node statements in it', function() {
|
||||
const res = flow.parser.parse('graph TD\nA-->B\nsubgraph myTitle\na b --> c e\n end;');
|
||||
|
||||
const vert = flow.parser.yy.getVertices();
|
||||
const edges = flow.parser.yy.getEdges();
|
||||
|
||||
expect(edges[0].type).toBe('arrow');
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user