File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed
store/test-store/tests/graphql Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -2880,6 +2880,31 @@ fn can_query_with_or_explicit_and_filter() {
2880
2880
} )
2881
2881
}
2882
2882
2883
+ #[ test]
2884
+ fn can_query_array_contains_nocase ( ) {
2885
+ const QUERY : & str = "
2886
+ query {
2887
+ musicians(where: { bands_contains_nocase: [\" B1\" , \" B2\" ] }) {
2888
+ name
2889
+ bands { id }
2890
+ }
2891
+ }
2892
+ " ;
2893
+
2894
+ run_query ( QUERY , |result, _| {
2895
+ let exp = object ! {
2896
+ musicians: vec![
2897
+ object! { name: "John" , bands: vec![ object! { id: "b1" } , object! { id: "b2" } ] } ,
2898
+ object! { name: "Lisa" , bands: vec![ object! { id: "b1" } ] } ,
2899
+ object! { name: "Tom" , bands: vec![ object! { id: "b1" } , object! { id: "b2" } ] } ,
2900
+ object! { name: "Paul" , bands: vec![ object! { id: "b2" } ] } ,
2901
+ ] ,
2902
+ } ;
2903
+ let data = extract_data ! ( result) . unwrap ( ) ;
2904
+ assert_eq ! ( data, exp) ;
2905
+ } )
2906
+ }
2907
+
2883
2908
#[ test]
2884
2909
fn can_query_with_or_implicit_and_filter ( ) {
2885
2910
const QUERY : & str = "
You can’t perform that action at this time.
0 commit comments