-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Test Report: Nested: File name too long #36996
Copy link
Copy link
Closed
Labels
a:regressionThis used to workThis used to workin:test-reportingTestEventReporter, test report aggregation, HTML test reports, XML test reportsTestEventReporter, test report aggregation, HTML test reports, XML test reports
Milestone
Description
Current Behavior
Upgrading the JetBrains/kotlin project to Gradle 9.4 caused build failures when generating test reports.
File name too long: '/opt/buildAgent/work/17e640964edd2053/kotlin/native/native.tests/klib-ir-inliner/build/reports/tests/test/org.jetbrains.kotlin.konan.test.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated/org.jetbrains.kotlin.konan.test.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box/org.jetbrains.kotlin.konan.test.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box$Ranges/org.jetbra-8UB7PO1MP775A.kotlin.konan.test.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box$Ranges$Stepped/o-U8GQRQ01FA18E.kotlin.konan.test.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box$Ranges$Stepped$Unsigned/org-8GQH5QGA24K4S.test.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box$Ranges$Stepped$Unsigned$Expression/o-L2QJDBRKVDRF2.blackbox.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box$Ranges$Stepped$Unsigned$Expression$DownTo/o-24H6DVU76EQE0.NativeCodegenBoxWithInlinedFunInKlibTestGenerated$Box$Ranges$Stepped$Unsigned$Expression$DownTo$Reversed/testStepThenReversedThenStepThenReversed().html'.
The very long pathname can be observed by using @Nested tests
class SampleTest {
@Nested
inner class ThisIsAVeryLongClassName {
@Nested
inner class ThisIsAVeryLongClassName1 {
@Nested
inner class ThisIsAVeryLongClassName2 {
@Nested
inner class ThisIsAVeryLongClassName3 {
@Nested
inner class ThisIsAVeryLongClassName4 {
@Test
fun thisIsAlsoARatherLongMethodName() {
println("Hello, world!")
}
}
}
}
}
}
}Nested tests will create a folder for each nesting with the FQN of the nested class. This can exceed the maximum path length.
Expected Behavior
I expect that @Nested tests, similar to static nested classes, generated a single filepath within bounds.
Context (optional)
No response
Self-contained Reproducer Project
Gradle version
9.4.0
Build scan URL (optional)
https://ge.jetbrains.com/s/6ccrtufthkfi4
Your Environment (optional)
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
a:regressionThis used to workThis used to workin:test-reportingTestEventReporter, test report aggregation, HTML test reports, XML test reportsTestEventReporter, test report aggregation, HTML test reports, XML test reports