@@ -152,40 +152,39 @@ public void Reader_Read_ParameterValue_Fails(string parameterName, string parame
152152 }
153153
154154 [ Theory ]
155- [ InlineData ( "filter" , "equals(title,'Brian O''Quote')" , null , "equals(title,'Brian O''Quote')" ) ]
156- [ InlineData ( "filter" , "equals(title,'!@#$%^&*()-_=+\" ''[]{}<>()/|\\ :;.,`~')" , null , "equals(title,'!@#$%^&*()-_=+\" ''[]{}<>()/|\\ :;.,`~')" ) ]
157- [ InlineData ( "filter" , "equals(title,'')" , null , "equals(title,'')" ) ]
158- [ InlineData ( "filter" , "startsWith(owner.displayName,'GivenName ')" , null , "startsWith(owner.displayName,'GivenName ')" ) ]
159- [ InlineData ( "filter" , "endsWith(owner.displayName,' Surname')" , null , "endsWith(owner.displayName,' Surname')" ) ]
160- [ InlineData ( "filter" , "contains(owner.displayName,' ')" , null , "contains(owner.displayName,' ')" ) ]
161- [ InlineData ( "filter[posts]" , "equals(caption,'this, that & more')" , "posts" , "equals(caption,'this, that & more')" ) ]
162- [ InlineData ( "filter[owner.posts]" , "equals(caption,'some')" , "owner.posts" , "equals(caption,'some')" ) ]
163- [ InlineData ( "filter[posts.comments]" , "equals(createdAt,'2000-01-01')" , "posts.comments" , "equals(createdAt,'2000-01-01')" ) ]
164- [ InlineData ( "filter" , "equals(count(posts),'1')" , null , "equals(count(posts),'1')" ) ]
165- [ InlineData ( "filter" , "equals(count(posts),count(owner.posts))" , null , "equals(count(posts),count(owner.posts))" ) ]
166- [ InlineData ( "filter[posts]" , "equals(caption,null)" , "posts" , "equals(caption,null)" ) ]
167- [ InlineData ( "filter[posts]" , "equals(author,null)" , "posts" , "equals(author,null)" ) ]
168- [ InlineData ( "filter[posts]" , "equals(author.userName,author.displayName)" , "posts" , "equals(author.userName,author.displayName)" ) ]
169- [ InlineData ( "filter[posts.comments]" , "lessThan(createdAt,'2000-01-01')" , "posts.comments" , "lessThan(createdAt,'2000-01-01')" ) ]
170- [ InlineData ( "filter[posts.comments]" , "lessOrEqual(createdAt,'2000-01-01')" , "posts.comments" , "lessOrEqual(createdAt,'2000-01-01')" ) ]
171- [ InlineData ( "filter[posts.comments]" , "greaterThan(createdAt,'2000-01-01')" , "posts.comments" , "greaterThan(createdAt,'2000-01-01')" ) ]
172- [ InlineData ( "filter[posts.comments]" , "greaterOrEqual(createdAt,'2000-01-01')" , "posts.comments" , "greaterOrEqual(createdAt,'2000-01-01')" ) ]
173- [ InlineData ( "filter" , "has(posts)" , null , "has(posts)" ) ]
174- [ InlineData ( "filter" , "has(posts,not(equals(url,null)))" , null , "has(posts,not(equals(url,null)))" ) ]
175- [ InlineData ( "filter" , "contains(title,'this')" , null , "contains(title,'this')" ) ]
176- [ InlineData ( "filter" , "startsWith(title,'this')" , null , "startsWith(title,'this')" ) ]
177- [ InlineData ( "filter" , "endsWith(title,'this')" , null , "endsWith(title,'this')" ) ]
178- [ InlineData ( "filter" , "any(title,'this')" , null , "any(title,'this')" ) ]
179- [ InlineData ( "filter" , "any(title,'this','that','there')" , null , "any(title,'that','there','this')" ) ]
180- [ InlineData ( "filter" , "and(contains(title,'sales'),contains(title,'marketing'),contains(title,'advertising'))" , null ,
181- "and(contains(title,'sales'),contains(title,'marketing'),contains(title,'advertising'))" ) ]
155+ [ InlineData ( "filter" , "equals(title,'Brian O''Quote')" , null ) ]
156+ [ InlineData ( "filter" , "equals(title,'!@#$%^&*()-_=+\" ''[]{}<>()/|\\ :;.,`~')" , null ) ]
157+ [ InlineData ( "filter" , "equals(title,'')" , null ) ]
158+ [ InlineData ( "filter" , "startsWith(owner.displayName,'GivenName ')" , null ) ]
159+ [ InlineData ( "filter" , "endsWith(owner.displayName,' Surname')" , null ) ]
160+ [ InlineData ( "filter" , "contains(owner.displayName,' ')" , null ) ]
161+ [ InlineData ( "filter[posts]" , "equals(caption,'this, that & more')" , "posts" ) ]
162+ [ InlineData ( "filter[owner.posts]" , "equals(caption,'some')" , "owner.posts" ) ]
163+ [ InlineData ( "filter[posts.comments]" , "equals(createdAt,'2000-01-01')" , "posts.comments" ) ]
164+ [ InlineData ( "filter" , "equals(count(posts),'1')" , null ) ]
165+ [ InlineData ( "filter" , "equals(count(posts),count(owner.posts))" , null ) ]
166+ [ InlineData ( "filter[posts]" , "equals(caption,null)" , "posts" ) ]
167+ [ InlineData ( "filter[posts]" , "equals(author,null)" , "posts" ) ]
168+ [ InlineData ( "filter[posts]" , "equals(author.userName,author.displayName)" , "posts" ) ]
169+ [ InlineData ( "filter[posts.comments]" , "lessThan(createdAt,'2000-01-01')" , "posts.comments" ) ]
170+ [ InlineData ( "filter[posts.comments]" , "lessOrEqual(createdAt,'2000-01-01')" , "posts.comments" ) ]
171+ [ InlineData ( "filter[posts.comments]" , "greaterThan(createdAt,'2000-01-01')" , "posts.comments" ) ]
172+ [ InlineData ( "filter[posts.comments]" , "greaterOrEqual(createdAt,'2000-01-01')" , "posts.comments" ) ]
173+ [ InlineData ( "filter" , "has(posts)" , null ) ]
174+ [ InlineData ( "filter" , "has(posts,not(equals(url,null)))" , null ) ]
175+ [ InlineData ( "filter" , "contains(title,'this')" , null ) ]
176+ [ InlineData ( "filter" , "startsWith(title,'this')" , null ) ]
177+ [ InlineData ( "filter" , "endsWith(title,'this')" , null ) ]
178+ [ InlineData ( "filter" , "any(title,'this')" , null ) ]
179+ [ InlineData ( "filter" , "any(title,'that','there','this')" , null ) ]
180+ [ InlineData ( "filter" , "and(contains(title,'sales'),contains(title,'marketing'),contains(title,'advertising'))" , null ) ]
182181 [ InlineData ( "filter[posts]" , "or(and(not(equals(author.userName,null)),not(equals(author.displayName,null))),not(has(comments,startsWith(text,'A'))))" ,
183- "posts" , "or(and(not(equals(author.userName,null)),not(equals(author.displayName,null))),not(has(comments,startsWith(text,'A'))))" ) ]
184- [ InlineData ( "filter" , "isType(owner.person,men)" , null , "isType(owner.person,men)" ) ]
185- [ InlineData ( "filter" , "isType(owner.person,men,equals(hasBeard,'true'))" , null , "isType(owner.person,men,equals(hasBeard,'true'))" ) ]
186- [ InlineData ( "filter[posts.contributors]" , "isType(,women)" , "posts.contributors" , "isType(,women)" ) ]
187- [ InlineData ( "filter[posts.contributors]" , "isType(,women,equals(maidenName,'Austen'))" , "posts.contributors" , "isType(,women,equals(maidenName,'Austen'))" ) ]
188- public void Reader_Read_Succeeds ( string parameterName , string parameterValue , string scopeExpected , string valueExpected )
182+ "posts" ) ]
183+ [ InlineData ( "filter" , "isType(owner.person,men)" , null ) ]
184+ [ InlineData ( "filter" , "isType(owner.person,men,equals(hasBeard,'true'))" , null ) ]
185+ [ InlineData ( "filter[posts.contributors]" , "isType(,women)" , "posts.contributors" ) ]
186+ [ InlineData ( "filter[posts.contributors]" , "isType(,women,equals(maidenName,'Austen'))" , "posts.contributors" ) ]
187+ public void Reader_Read_Succeeds ( string parameterName , string parameterValue , string scopeExpected )
189188 {
190189 // Act
191190 _reader . Read ( parameterName , parameterValue ) ;
@@ -197,6 +196,6 @@ public void Reader_Read_Succeeds(string parameterName, string parameterValue, st
197196 scope ? . ToString ( ) . Should ( ) . Be ( scopeExpected ) ;
198197
199198 QueryExpression value = constraints . Select ( expressionInScope => expressionInScope . Expression ) . Single ( ) ;
200- value . ToString ( ) . Should ( ) . Be ( valueExpected ) ;
199+ value . ToString ( ) . Should ( ) . Be ( parameterValue ) ;
201200 }
202201}
0 commit comments