Skip to content

Conversation

jyemin
Copy link
Collaborator

@jyemin jyemin commented Jul 23, 2025

Previously, for a parameterized test like
CrudProseTest::testBulkWriteHandlesWriteErrorsAcrossBatches, the test cases in the tests results XML output (and therefore the Evergreen UI) appear as

 <testcase name="[1] false" classname="com.mongodb.reactivestreams.client.CrudProseTest""/> <testcase name="[2] true" classname="com.mongodb.reactivestreams.client.CrudProseTest"/> 

Making it quite confusing to figure out which test it actually is.

After this change, they will appear as

 <testcase name="6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:false" classname="com.mongodb.reactivestreams.client.CrudProseTest"/> <testcase name="6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:true" classname="com.mongodb.reactivestreams.client.CrudProseTest"/> 

and in the IDEA UI like

 6. MongoClient.bulkWrite handles individual WriteErrors across batches --ordered:false --ordered:true 

and in Gradle output like

 6. MongoClient.bulkWrite handles individual WriteErrors across batches Test 6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:false PASSED Test 6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:true PASSED 
@jyemin jyemin self-assigned this Jul 23, 2025
@jyemin jyemin requested a review from a team as a code owner July 23, 2025 17:28
@jyemin jyemin requested review from rozza and removed request for a team July 23, 2025 17:28
@jyemin jyemin force-pushed the fix-parameterized-test-names-in-crud-prose-test branch from 6ed0ddc to 1474e3e Compare July 23, 2025 17:28
Previously, for a parameterized test like CrudProseTest::testBulkWriteHandlesWriteErrorsAcrossBatches, the test names in the JUnit XML output (and therefore in CI) were [1] false [2] true Now the test names are 6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:false 6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:true and appear in the IDEA UI like 6. MongoClient.bulkWrite handles individual WriteErrors across batches --ordered:false --ordered:true and in Gradle output like 6. MongoClient.bulkWrite handles individual WriteErrors across batches Test 6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:false PASSED (5.1s) Test 6. MongoClient.bulkWrite handles individual WriteErrors across batches--ordered:true PASSED
@jyemin jyemin force-pushed the fix-parameterized-test-names-in-crud-prose-test branch from 1474e3e to fb26b29 Compare July 23, 2025 19:00
Copy link
Member

@rozza rozza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jyemin jyemin requested a review from vbabanin July 24, 2025 13:28
@jyemin jyemin merged commit 8d7c0dc into mongodb:main Jul 24, 2025
47 of 55 checks passed
@jyemin jyemin deleted the fix-parameterized-test-names-in-crud-prose-test branch July 24, 2025 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants