Skip to content

Fix test grouping on TeamCity for Gradle 9.3#2973

Open
labkey-tchad wants to merge 4 commits intorelease26.3-SNAPSHOTfrom
26.3_fb_fixJUnitTestLogging
Open

Fix test grouping on TeamCity for Gradle 9.3#2973
labkey-tchad wants to merge 4 commits intorelease26.3-SNAPSHOTfrom
26.3_fb_fixJUnitTestLogging

Conversation

@labkey-tchad
Copy link
Copy Markdown
Member

Rationale

In Gradle 9.3, they changed how it reports test results.
Test names within nested test suites (such as the one built by JUnitTest) now include a bunch of summary information. This information (specifically the test count) varies between different suites and will vary over time as we add or remove tests. Having consistent test names is important for tracking test responsibility across different suites and tracking results over time.

e.g.

TestSuite with 384 tests [example: org.labkey.test.util.JUnitHeader]: Remote Experiment: org.labkey.test.tests.JUnitTest$RemoteTest.org.labkey.api.exp.Lsid$TestCase 

instead of:

exp.Lsid$TestCase

Flattening the nested test suites when running on TeamCity reverts to the old test names.

Related Pull Requests

  • N/A

Changes

@labkey-tchad labkey-tchad self-assigned this May 1, 2026
@labkey-jeckels
Copy link
Copy Markdown
Contributor

Hooray.

return null;
}

private static void flattenSuiteInto(TestSuite destination, TestSuite source)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nit: Why not just flattenSuite ? The unanswered 'Into' is strange.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants