File tree Expand file tree Collapse file tree 2 files changed +21
-3
lines changed
Expand file tree Collapse file tree 2 files changed +21
-3
lines changed Original file line number Diff line number Diff line change 2020 CodeMirror . defineMode ( "cypher" , function ( config ) {
2121 var tokenBase = function ( stream /*, state*/ ) {
2222 var ch = stream . next ( ) ;
23- if ( ch === "\"" ) {
24- stream . match ( / .+ ? [ " ] / ) ;
23+ if ( ch === '"' ) {
24+ stream . match ( / .* ? " / ) ;
2525 return "string" ;
2626 }
2727 if ( ch === "'" ) {
28- stream . match ( / .+ ? [ ' ] / ) ;
28+ stream . match ( / .* ? ' / ) ;
2929 return "string" ;
3030 }
3131 if ( / [ { } \( \) , \. ; \[ \] ] / . test ( ch ) ) {
Original file line number Diff line number Diff line change 1616
1717 MT ( "singleQuotedString" ,
1818 "[string 'a'][variable b]" ) ;
19+
20+ MT ( "single attribute (with content)" ,
21+ "[node {][atom a:][string 'a'][node }]" ) ;
22+
23+ MT ( "multiple attribute, singleQuotedString (with content)" ,
24+ "[node {][atom a:][string 'a'][node ,][atom b:][string 'b'][node }]" ) ;
25+
26+ MT ( "multiple attribute, doubleQuotedString (with content)" ,
27+ "[node {][atom a:][string \"a\"][node ,][atom b:][string \"b\"][node }]" ) ;
28+
29+ MT ( "single attribute (without content)" ,
30+ "[node {][atom a:][string 'a'][node }]" ) ;
31+
32+ MT ( "multiple attribute, singleQuotedString (without content)" ,
33+ "[node {][atom a:][string ''][node ,][atom b:][string ''][node }]" ) ;
34+
35+ MT ( "multiple attribute, doubleQuotedString (without content)" ,
36+ "[node {][atom a:][string \"\"][node ,][atom b:][string \"\"][node }]" ) ;
1937 } ) ( ) ;
You can’t perform that action at this time.
0 commit comments