File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed
Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -125,6 +125,29 @@ fragment MissingOn Type
125125 ) . to . throw ( 'Syntax Error GraphQL (1:39) Unexpected Name "null"' ) ;
126126 } ) ;
127127
128+ it ( 'parses multi-byte characters' , async ( ) => {
129+ // Note: \u0A0A could be naively interpretted as two line-feed chars.
130+ expect (
131+ parse ( `
132+ # This comment has a \u0A0A multi-byte character.
133+ { field(arg: "Has a \u0A0A multi-byte character.") }
134+ ` )
135+ ) . to . containSubset ( {
136+ definitions : [ {
137+ selectionSet : {
138+ selections : [ {
139+ arguments : [ {
140+ value : {
141+ kind : Kind . STRING ,
142+ value : 'Has a \u0A0A multi-byte character.'
143+ }
144+ } ]
145+ } ]
146+ }
147+ } ]
148+ } ) ;
149+ } ) ;
150+
128151 var kitchenSink = readFileSync (
129152 join ( __dirname , '/kitchen-sink.graphql' ) ,
130153 { encoding : 'utf8' }
You can’t perform that action at this time.
0 commit comments