build: upgrade TestNG 7.8.0 -> 7.9.0 - #206
Open
devin-ai-integration[bot] wants to merge 1 commit into
Open
Conversation
Highest TestNG 7.x compatible with the project's Gradle 7.4 TestNG integration; 7.10.0+ adds ITestNGListener.isEnabled(), which Gradle 7.4's listener adapter cannot proxy.
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Upgrades the TestNG test dependency, the only coordinate touched:
Why 7.9.0 and not 7.11.0 (the newest stable 7.x): TestNG 7.10.0 added
isEnabled()toITestNGListener. Gradle 7.4'sTestNGListenerAdapterFactoryproxies its own listeners and cannot answer that call, soseleniumTestdies before running a single test on 7.10.x/7.11.0:Verified empirically on this branch: 7.11.0 FAILED, 7.10.2 FAILED, 7.9.0 PASSED. Fixing it would require bumping the Gradle wrapper (out of scope for this PR — only the assigned dependency may move), so 7.9.0 is the highest TestNG 7.x that works on Gradle 7.4 + Java 11 + Boot 2.6.3. 7.9.0 is a stable release published 2023-12-26 (no
-M/-RC/-alpha/-beta, far older than 7 days).BOM /
extoverridesNone required. The Spring Boot 2.6.3 BOM does not manage
org.testng:testng, so the literal version inbuild.gradleis what resolves.dependencyInsight evidence
JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64 ./gradlew dependencyInsight --configuration testRuntimeClasspath --dependency org.testng:testngorg.gradle.jvm.version = 11confirms the Java 11 baseline of the published variant.Transitives (no downgrades, no split families, identical to the 7.8.0 baseline):
com.beust:jcommander:1.82com.beust:jcommander:1.821.7.33(Boot BOM pin)1.7.33(Boot BOM pin)TestNG 7.9.0 requests
org.slf4j:slf4j-api:1.7.36, which the Boot 2.6.3 BOM pins to1.7.33— the same pre-existing pin that applied to 7.8.0 (webdrivermanagerlikewise requests2.0.9 -> 1.7.33on both sides). No new downgrade is introduced by this change. Note that TestNG 7.10.0+ would also have moved jcommander to the neworg.jcommander:jcommandergroup; staying on 7.9.0 keeps the classpath unchanged.API migration
No source changes needed. All TestNG API used by the Selenium suite is unchanged between 7.8.0 and 7.9.0:
src/test/java/io/spring/selenium/listeners/TestListener.java—ITestContext,ITestListener,ITestResultsrc/test/java/io/spring/selenium/tests/BaseTest.java—ITestResult,org.testng.annotations.*src/test/java/io/spring/selenium/tests/SeleniumSetupTest.java— staticorg.testng.Assert.*,@Testsrc/test/resources/selenium/testng-smoke.xmlstill parses (the suite ran to completion).7.8.0appears nowhere else in the tracked tree, so no stale references to update.Gate output
JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64 ./gradlew clean test spotlessCheck -x jacocoTestCoverageVerificationTest results parsed from
build/test-results/test/*.xml: 68 tests, 0 failures, 0 errors, 0 skipped — exactly the recorded baseline on untouchedmain(68/0/0/0).Additional checks:
./gradlew compileTestJava→BUILD SUCCESSFUL./gradlew seleniumTest→BUILD SUCCESSFUL, bothSeleniumSetupTestcases PASSED (testBrowserLaunches,testWebDriverManagerSetup)Pre-existing on base, not addressed here
jacocoTestCoverageVerificationfails at ~0.33 instruction coverage against the 0.80 rule inbuild.gradle. This is red on untouchedmain; CI excludes it (-x jacocoTestCoverageVerification) and so does this PR's gate. Threshold untouched, no coverage tests added.spotlessJavaimplicit-dependency validation warnings and Gradle 8.0 deprecation warnings on both base and this branch. Unrelated to this change.Link to Devin session: https://partner-workshops.devinenterprise.com/sessions/7e5e8d52b22649ef8d58dc065f0c0134
Requested by: @mbatchelor81