#834 Using space as separator, simplfifying the grammar some more, reomving some logging

This commit is contained in:
Knut Sveidqvist
2019-12-18 18:36:34 +01:00
parent 6598b1b10d
commit 42ef035241
5 changed files with 31 additions and 40 deletions

View File

@@ -192,6 +192,15 @@ describe('when parsing subgraphs', function() {
expect(edges[0].type).toBe('arrow');
});
it('should handle subgraphs3', function() {
const res = flow.parser.parse('graph TD\nA-->B\nsubgraph myTitle \n\n c-->d \nend\n');
const vert = flow.parser.yy.getVertices();
const edges = flow.parser.yy.getEdges();
expect(edges[0].type).toBe('arrow');
});
it('should handle nested subgraphs', function() {
const str =
'graph TD\n' +