This is a test-only companion for the reviewed PR (which changes getSeleniumAddress() in org.testcontainers.containers.BrowserWebDriverContainer and org.testcontainers.selenium.BrowserWebDriverContainer to throw ContainerLaunchException instead of printStackTrace() + return null on MalformedURLException).
Why
No existing test exercised getSeleniumAddress() or its failure branch, so the PR's new fail-fast contract was unlocked. Adding focused tests proves both the unchanged normal-path URL construction and the new throw-instead-of-null-return behavior without needing Docker, using the same test-subclass pattern already established in modules/postgresql/src/test/java/org/testcontainers/containers/PostgreSQLConnectionURLTest.java (override getHost()/getMappedPort(int)).
Evidence
behavior_baseline and behavior_candidate: identical focused command, 4/4 tests passed both times (production code unchanged).
Spotless and Checkstyle pass on the new test files.
Full non-Docker build (assemble, compileTestJava, spotless, checkstyle, focused tests) passes.
The module's Docker-backed integration suite cannot run in this sandbox (no Docker daemon); confirmed the same 20 tests fail identically on the unmodified PR head, so this is a pre-existing environment limitation, not a regression.
Scope
No production code was changed: the PR's two-line-per-file diff was already minimal, correct, and consistent with the repository's existing ContainerLaunchException usage a few lines above in the same configure() methods. Cleanup, performance, and modernization passes found nothing safely improvable within this bounded PR's changed lines.
Generated by JAIPilot Cloud for #1 from Anthropic session sesn_0116YsXpJ6MhMWR6oGdbAyAj.
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
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.
What
This is a test-only companion for the reviewed PR (which changes getSeleniumAddress() in org.testcontainers.containers.BrowserWebDriverContainer and org.testcontainers.selenium.BrowserWebDriverContainer to throw ContainerLaunchException instead of printStackTrace() + return null on MalformedURLException).
Why
No existing test exercised getSeleniumAddress() or its failure branch, so the PR's new fail-fast contract was unlocked. Adding focused tests proves both the unchanged normal-path URL construction and the new throw-instead-of-null-return behavior without needing Docker, using the same test-subclass pattern already established in modules/postgresql/src/test/java/org/testcontainers/containers/PostgreSQLConnectionURLTest.java (override getHost()/getMappedPort(int)).
Evidence
Scope
No production code was changed: the PR's two-line-per-file diff was already minimal, correct, and consistent with the repository's existing ContainerLaunchException usage a few lines above in the same configure() methods. Cleanup, performance, and modernization passes found nothing safely improvable within this bounded PR's changed lines.
Generated by JAIPilot Cloud for #1 from Anthropic session sesn_0116YsXpJ6MhMWR6oGdbAyAj.