-
Notifications
You must be signed in to change notification settings - Fork 119
Description
TCK Details
- TCK Specification
- Jakarta Context and Dependency Injection 4.1
- Coordinates
jakarta.tck:cdi-tck-ee-impl:11.0.1
- TCK Version
- 11.0.1
- Implementation
- WildFly, Red Hat
Description
The CDI TCK implementation (specifically tests utilizing ChromeDevtoolsDriver, such as LongRunningConversationPropagatedByFacesContextTest) fails to execute in environments where the installed version of Google Chrome is newer than version 126. This test affects Jakarta EE 11 Platform Tests and Jakarta Context and Dependency Injection 4.1.
The TCK depends on selenium-devtools-v126 (via the Selenium 4.24.0 BOM). This creates a hard dependency on the Chrome DevTools Protocol (CDP) v126. However, the test runner logic does not provide a functional mechanism to configure the browser binary location, forcing the WebDriver to default to the system-installed browser (e.g., current Chrome Stable v142).
Because CDP v126 cannot communicate with Chrome v142, the test fails immediately with a DevToolsException. Extensive attempts to configure the binary path via standard Selenium system properties (webdriver.chrome.binary), WebDriverManager properties (wdm.chromeBinary), and environment variables have failed. This indicates that the TCK runner logic (combined with WebDriverManager usage and Maven forking) isolates or ignores these configurations during execution.
Likely Cause
The class org.jboss.cdi.tck.selenium.ChromeDevtoolsDriver initializes new ChromeOptions() and passes it to new ChromeDriver(options) without propagating binary configuration properties.
Additionally, the environment implicitly uses WebDriverManager 6.1.0. While WDM manages the driver version successfully, the lack of a mechanism to force the browser binary (coupled with the inability to use wdm.dockerEnabled within the existing TCK structure) results in an unavoidable version mismatch on modern systems.
Steps to Reproduce
- Run the TCK on a system with a current stable Google Chrome installed (e.g., v142).
- Execute the CDI TCK Runner (Platform TCK).
- Run the test:
org.jboss.cdi.tck.tests.context.conversation.LongRunningConversationPropagatedByFacesContextTest. - Observe the failure during driver initialization.
Log Output
[client] ... FINE [org.openqa.selenium.remote.service.DriverFinder] (main) Skipping Selenium Manager, path to chromedriver found in system property: .../chromedriver/linux64/126.0.6478.182/chromedriver
...
[client] ... FINE [org.openqa.selenium.remote.RemoteWebDriver] (Forwarding newSession on session null to remote) Exception: newSession Could not start a new session. Response code 500. Message: session not created: This version of ChromeDriver only supports Chrome version 126
Current browser version is 142.0.7444.162 with binary path /opt/google/chrome/chrome
...
org.openqa.selenium.devtools.DevToolsException: You are using a no-op implementation of the CDP. The most likely reason for this is that Selenium was unable to find an implementation of the CDP protocol that matches your browser.
Related Issues / References
- TCK Challenge: testConversationPropagatedAjax using HTMLUnit is incompatible with modern Typescript implementations cdi-tck#434
- Revisit htmlunit usage in CDI TCK #1228
- Add Support for Selenium Tests cdi-tck#437
Proposed Solution / Justification for Challenge
The TCK is currently unportable to standard CI/local environments that maintain up-to-date browsers.
We request that this test failure be marked as a valid TCK Challenge / Exclude until one of the following fixes is applied to the TCK:
- Upgrade Selenium: Update the Selenium dependency to a version compatible with the current Chrome Stable channel (e.g., Selenium 4.27+).
- Enable Configuration: Refactor
ChromeDevtoolsDriverto explicitly respectwebdriver.chrome.binaryorwdm.chromeBinary. - Rewrite the tests to use something other than Selenium like PlayWrite, I don't recall where this was suggested.