@@ -43,8 +43,8 @@ static void test_mc_TextOpts_parse(_mongocrypt_tester_t *tester) {
4343 testcase tests [] = {
4444 {.desc = "Works with minimal options" ,
4545 .in = RAW_STRING ({
46- "caseSensitive" : false ,
47- "diacriticSensitive" : true ,
46+ "caseSensitive" : true ,
47+ "diacriticSensitive" : false ,
4848 "prefix" : {"strMinQueryLength" : 1 , "strMaxQueryLength" : 2 }
4949 }),
5050 .expectCaseSensitive = true,
@@ -54,8 +54,8 @@ static void test_mc_TextOpts_parse(_mongocrypt_tester_t *tester) {
5454 .expectPrefixStrMaxQueryLength = 2 },
5555 {.desc = "Works with substring options" ,
5656 .in = RAW_STRING ({
57- "caseSensitive" : false ,
58- "diacriticSensitive" : true ,
57+ "caseSensitive" : true ,
58+ "diacriticSensitive" : false ,
5959 "substring" : {"strMaxLength" : 10 , "strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
6060 }),
6161 .expectCaseSensitive = true,
@@ -69,24 +69,24 @@ static void test_mc_TextOpts_parse(_mongocrypt_tester_t *tester) {
6969 .expectError = "One of 'prefix', 'suffix', or 'substring' is required" },
7070 {.desc = "Errors if substring, prefix, and suffix are all provided" ,
7171 .in = RAW_STRING ({
72- "caseSensitive" : false ,
73- "diacriticSensitive" : true ,
72+ "caseSensitive" : true ,
73+ "diacriticSensitive" : false ,
7474 "substring" : {"strMaxLength" : 10 , "strMinQueryLength" : 3 , "strMaxQueryLength" : 8 },
7575 "prefix" : {"strMinQueryLength" : 2 , "strMaxQueryLength" : 10 },
7676 "suffix" : {"strMinQueryLength" : 4 , "strMaxQueryLength" : 12 }
7777 }),
7878 .expectError = "Cannot specify 'substring' with 'prefix' or 'suffix'" },
7979 {.desc = "Errors if strMaxLength is present in prefix" ,
8080 .in = RAW_STRING ({
81- "caseSensitive" : false ,
82- "diacriticSensitive" : true ,
81+ "caseSensitive" : true ,
82+ "diacriticSensitive" : false ,
8383 "prefix" : {"strMaxLength" : 12 , "strMinQueryLength" : 2 , "strMaxQueryLength" : 10 }
8484 }),
8585 .expectError = "'strMaxLength' is not allowed in 'prefix'" },
8686 {.desc = "Errors if strMaxLength is present in suffix" ,
8787 .in = RAW_STRING ({
88- "caseSensitive" : false ,
89- "diacriticSensitive" : true ,
88+ "caseSensitive" : true ,
89+ "diacriticSensitive" : false ,
9090 "suffix" : {"strMaxLength" : 15 , "strMinQueryLength" : 4 , "strMaxQueryLength" : 12 }
9191 }),
9292 .expectError = "'strMaxLength' is not allowed in 'suffix'" },
@@ -157,52 +157,52 @@ static void test_mc_TextOpts_to_FLE2TextSearchInsertSpec(_mongocrypt_tester_t *t
157157 testcase tests [] = {
158158 {.desc = "Works with substring" ,
159159 .in = RAW_STRING ({
160- "caseSensitive" : false ,
161- "diacriticSensitive" : true ,
160+ "caseSensitive" : true ,
161+ "diacriticSensitive" : false ,
162162 "substring" : {"strMaxLength" : 10 , "strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
163163 }),
164164 .v = RAW_STRING ({"v" : "test "}),
165165 .expect = RAW_STRING (
166- {"v" : {"v" : "test ", " casef " : false , " diacf " : true , " substr " : {" mlen " : 10, " ub " : 8, " lb " : 3}}})},
166+ {"v" : {"v" : "test ", " casef " : true , " diacf " : false , " substr " : {" mlen " : 10, " ub " : 8, " lb " : 3}}})},
167167 {.desc = "Works with prefix" ,
168168 .in = RAW_STRING ({
169- "caseSensitive" : false ,
170- "diacriticSensitive" : true ,
169+ "caseSensitive" : true ,
170+ "diacriticSensitive" : false ,
171171 "prefix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
172172 }),
173173 .v = RAW_STRING ({"v" : "test "}),
174174 .expect =
175- RAW_STRING ({"v" : {"v" : "test ", " casef " : false , " diacf " : true , " prefix " : {" ub " : 8, " lb " : 3}}})},
175+ RAW_STRING ({"v" : {"v" : "test ", " casef " : true , " diacf " : false , " prefix " : {" ub " : 8, " lb " : 3}}})},
176176 {.desc = "Works with suffix" ,
177177 .in = RAW_STRING ({
178- "caseSensitive" : false ,
179- "diacriticSensitive" : true ,
178+ "caseSensitive" : true ,
179+ "diacriticSensitive" : false ,
180180 "suffix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
181181 }),
182182 .v = RAW_STRING ({"v" : "test "}),
183183 .expect =
184- RAW_STRING ({"v" : {"v" : "test ", " casef " : false , " diacf " : true , " suffix " : {" ub " : 8, " lb " : 3}}})},
184+ RAW_STRING ({"v" : {"v" : "test ", " casef " : true , " diacf " : false , " suffix " : {" ub " : 8, " lb " : 3}}})},
185185 {.desc = "Works with prefix + suffix" ,
186186 .in = RAW_STRING ({
187- "caseSensitive" : false ,
188- "diacriticSensitive" : true ,
187+ "caseSensitive" : true ,
188+ "diacriticSensitive" : false ,
189189 "prefix" : {"strMinQueryLength" : 4 , "strMaxQueryLength" : 9 },
190190 "suffix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
191191 }),
192192 .v = RAW_STRING ({"v" : "test "}),
193193 .expect = RAW_STRING ({
194194 "v" : {
195195 "v" : "test ",
196- " casef " : false ,
197- " diacf " : true ,
196+ " casef " : true ,
197+ " diacf " : false ,
198198 " prefix " : {" ub " : 9, " lb " : 4},
199199 " suffix " : {" ub " : 8, " lb " : 3}
200200 }
201201 })},
202202 {.desc = "Errors with missing v" ,
203203 .in = RAW_STRING ({
204- "caseSensitive" : false ,
205- "diacriticSensitive" : true ,
204+ "caseSensitive" : true ,
205+ "diacriticSensitive" : false ,
206206 "prefix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
207207 }),
208208 .v = RAW_STRING ({"foo" : "bar "}),
@@ -240,8 +240,8 @@ static void test_mc_TextOpts_to_FLE2TextSearchInsertSpec_for_query(_mongocrypt_t
240240 testcase tests [] = {
241241 {.desc = "Works with substring" ,
242242 .in = RAW_STRING ({
243- "caseSensitive" : false ,
244- "diacriticSensitive" : true ,
243+ "caseSensitive" : true ,
244+ "diacriticSensitive" : false ,
245245 "substring" : {"strMaxLength" : 10 , "strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
246246 }),
247247 .v = RAW_STRING ({"v" : "test "}),
@@ -250,8 +250,8 @@ static void test_mc_TextOpts_to_FLE2TextSearchInsertSpec_for_query(_mongocrypt_t
250250 {"v" : {"v" : "test ", " casef " : true, " diacf " : false, " substr " : {" mlen " : 10, " ub " : 8, " lb " : 3}}})},
251251 {.desc = "Works with prefix" ,
252252 .in = RAW_STRING ({
253- "caseSensitive" : false ,
254- "diacriticSensitive" : true ,
253+ "caseSensitive" : true ,
254+ "diacriticSensitive" : false ,
255255 "prefix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
256256 }),
257257 .v = RAW_STRING ({"v" : "test "}),
@@ -260,8 +260,8 @@ static void test_mc_TextOpts_to_FLE2TextSearchInsertSpec_for_query(_mongocrypt_t
260260 RAW_STRING ({"v" : {"v" : "test ", " casef " : true, " diacf " : false, " prefix " : {" ub " : 8, " lb " : 3}}})},
261261 {.desc = "Works with suffix" ,
262262 .in = RAW_STRING ({
263- "caseSensitive" : false ,
264- "diacriticSensitive" : true ,
263+ "caseSensitive" : true ,
264+ "diacriticSensitive" : false ,
265265 "suffix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
266266 }),
267267 .v = RAW_STRING ({"v" : "test "}),
@@ -270,8 +270,8 @@ static void test_mc_TextOpts_to_FLE2TextSearchInsertSpec_for_query(_mongocrypt_t
270270 RAW_STRING ({"v" : {"v" : "test ", " casef " : true, " diacf " : false, " suffix " : {" ub " : 8, " lb " : 3}}})},
271271 {.desc = "Works with prefix + suffix when querying prefix" ,
272272 .in = RAW_STRING ({
273- "caseSensitive" : false ,
274- "diacriticSensitive" : true ,
273+ "caseSensitive" : true ,
274+ "diacriticSensitive" : false ,
275275 "prefix" : {"strMinQueryLength" : 4 , "strMaxQueryLength" : 9 },
276276 "suffix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
277277 }),
@@ -281,8 +281,8 @@ static void test_mc_TextOpts_to_FLE2TextSearchInsertSpec_for_query(_mongocrypt_t
281281 RAW_STRING ({"v" : {"v" : "test ", " casef " : true, " diacf " : false, " prefix " : {" ub " : 9, " lb " : 4}}})},
282282 {.desc = "Works with prefix + suffix when querying suffix" ,
283283 .in = RAW_STRING ({
284- "caseSensitive" : false ,
285- "diacriticSensitive" : true ,
284+ "caseSensitive" : true ,
285+ "diacriticSensitive" : false ,
286286 "prefix" : {"strMinQueryLength" : 4 , "strMaxQueryLength" : 9 },
287287 "suffix" : {"strMinQueryLength" : 3 , "strMaxQueryLength" : 8 }
288288 }),
0 commit comments