@@ -4969,6 +4969,7 @@ test_bulk_write_multiple_errors (void *unused)
4969
4969
4970
4970
client = test_framework_new_default_client ();
4971
4971
BSON_ASSERT (client );
4972
+ mongoc_client_set_appname (client , "test_bulk_write_multiple_errors" );
4972
4973
4973
4974
collection = get_test_collection (client , "test_bulk_write_multiple_errors" );
4974
4975
BSON_ASSERT (collection );
@@ -4977,12 +4978,13 @@ test_bulk_write_multiple_errors (void *unused)
4977
4978
// the first error.
4978
4979
bson_append_bool (& opts , "ordered" , 7 , false);
4979
4980
bulk = mongoc_collection_create_bulk_operation_with_opts (collection , & opts );
4981
+ // Use appName to isolate the failpoint to this test.
4980
4982
bool ret = mongoc_client_command_simple (
4981
4983
client ,
4982
4984
"admin" ,
4983
- tmp_bson (
4984
- "{'configureFailPoint ': 'failCommand ', 'mode': {'times': 2}, "
4985
- "'data': {'failCommands': ['insert', 'delete'] , 'errorCode ': 8 }}" ),
4985
+ tmp_bson ("{'configureFailPoint': 'failCommand', 'mode': {'times': 2}, "
4986
+ "'data': {'failCommands ': ['insert ', 'delete'], 'errorCode': "
4987
+ "8 , 'appName ': 'test_bulk_write_multiple_errors' }}" ),
4986
4988
NULL ,
4987
4989
NULL ,
4988
4990
& error );
@@ -5326,5 +5328,7 @@ test_bulk_install (TestSuite *suite)
5326
5328
test_bulk_write_multiple_errors ,
5327
5329
NULL ,
5328
5330
NULL ,
5329
- test_framework_skip_if_no_failpoint );
5331
+ test_framework_skip_if_no_failpoint ,
5332
+ /* Require server 4.2 for failCommand appName */
5333
+ test_framework_skip_if_max_wire_version_less_than_8 );
5330
5334
}
0 commit comments