Version 0.1.0

This commit is contained in:
Knut Sveidqvist
2014-11-16 19:00:01 +01:00
committed by knsv
parent 75f3580e9a
commit 214bb77688
19 changed files with 360 additions and 2303 deletions

View File

@@ -145,6 +145,15 @@ describe('when parsing ',function(){
expect(vert['C'].type).toBe('diamond');
expect(vert['C'].text).toBe('Chimpansen hoppar åäö-ÅÄÖ');
});
it('should handle text in vertices with åäö, minus and space',function(){
var res = parser.parse('graph TD;A-->C{Chimpansen hoppar åäö - ÅÄÖ};');
var vert = parser.yy.getVertices();
var edges = parser.yy.getEdges();
expect(vert['C'].type).toBe('diamond');
expect(vert['C'].text).toBe('Chimpansen hoppar åäö - ÅÄÖ');
});
it('should handle a single node',function(){
// Silly but syntactically correct