@@ -146,7 +146,12 @@ tests:
146
146
arguments:
147
147
document: &doc4 { _id: 1, encrypted_double: {"$numberDouble": "1.23"} }
148
148
result:
149
- errorContains: "Cannot use deterministic encryption for element of type: double"
149
+ # DRIVERS-2272: The expected error message changed in mongocryptd 6.0. Before it was:
150
+ # "Cannot use deterministic encryption for element of type: double"
151
+ # After it is:
152
+ # "Cannot encrypt element of type: double"
153
+ # Only check for the common suffix.
154
+ errorContains: "element of type: double"
150
155
- description: "type=decimal"
151
156
clientOptions:
152
157
autoEncryptOpts:
@@ -159,7 +164,12 @@ tests:
159
164
arguments:
160
165
document: &doc5 { _id: 1, encrypted_decimal: {"$numberDecimal": "1.23"} }
161
166
result:
162
- errorContains: "Cannot use deterministic encryption for element of type: decimal"
167
+ # DRIVERS-2272: The expected error message changed in mongocryptd 6.0. Before it was:
168
+ # "Cannot use deterministic encryption for element of type: decimal"
169
+ # After it is:
170
+ # "Cannot encrypt element of type: decimal"
171
+ # Only check for the common suffix.
172
+ errorContains: "element of type: decimal"
163
173
- description: "type=binData"
164
174
clientOptions:
165
175
autoEncryptOpts:
@@ -254,7 +264,12 @@ tests:
254
264
arguments:
255
265
document: &doc8 { _id: 1, encrypted_javascriptWithScope: {"$code": "var x = 1;", "$scope": {} } }
256
266
result:
257
- errorContains: "Cannot use deterministic encryption for element of type: javascriptWithScope"
267
+ # DRIVERS-2272: The expected error message changed in mongocryptd 6.0. Before it was:
268
+ # "Cannot use deterministic encryption for element of type: javascriptWithScope"
269
+ # After it is:
270
+ # "Cannot encrypt element of type: javascriptWithScope"
271
+ # Only check for the common suffix.
272
+ errorContains: "element of type: javascriptWithScope"
258
273
- description: "type=object"
259
274
clientOptions:
260
275
autoEncryptOpts:
@@ -267,7 +282,12 @@ tests:
267
282
arguments:
268
283
document: &doc9 { _id: 1, encrypted_object: {} }
269
284
result:
270
- errorContains: "Cannot use deterministic encryption for element of type: object"
285
+ # DRIVERS-2272: The expected error message changed in mongocryptd 6.0. Before it was:
286
+ # "Cannot use deterministic encryption for element of type: object"
287
+ # After it is:
288
+ # "Cannot encrypt element of type: object"
289
+ # Only check for the common suffix.
290
+ errorContains: "element of type: object"
271
291
- description: "type=timestamp"
272
292
clientOptions:
273
293
autoEncryptOpts:
@@ -442,7 +462,12 @@ tests:
442
462
arguments:
443
463
document: &doc17 { _id: 1, encrypted_array: [] }
444
464
result:
445
- errorContains: "Cannot use deterministic encryption for element of type: array"
465
+ # DRIVERS-2272: The expected error message changed in mongocryptd 6.0. Before it was:
466
+ # "Cannot use deterministic encryption for element of type: array"
467
+ # After it is:
468
+ # "Cannot encrypt element of type: array"
469
+ # Only check for the common suffix.
470
+ errorContains: "element of type: array"
446
471
- description: "type=bool"
447
472
clientOptions:
448
473
autoEncryptOpts:
@@ -455,7 +480,12 @@ tests:
455
480
arguments:
456
481
document: &doc18 { _id: 1, encrypted_bool: true }
457
482
result:
458
- errorContains: "Cannot use deterministic encryption for element of type: bool"
483
+ # DRIVERS-2272: The expected error message changed in mongocryptd 6.0. Before it was:
484
+ # "Cannot use deterministic encryption for element of type: bool"
485
+ # After it is:
486
+ # "Cannot encrypt element of type: bool"
487
+ # Only check for the common suffix.
488
+ errorContains: "element of type: bool"
459
489
- description: "type=null"
460
490
clientOptions:
461
491
autoEncryptOpts:
0 commit comments