From 22d0f9acdcb61f40cdd36c459c46daab816f0df5 Mon Sep 17 00:00:00 2001 From: Alex Pott Date: Wed, 13 Aug 2025 16:13:09 +0100 Subject: [PATCH 1/2] Test on PHP 8.4 --- .ddev/config.yaml | 2 +- .github/workflows/Tests.yml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.ddev/config.yaml b/.ddev/config.yaml index 1a3f3a6..bf8bf5f 100644 --- a/.ddev/config.yaml +++ b/.ddev/config.yaml @@ -1,7 +1,7 @@ name: php-webdriver type: php docroot: "" -php_version: "8.3" +php_version: "8.4" webserver_type: nginx-fpm xdebug_enabled: false additional_hostnames: [] diff --git a/.github/workflows/Tests.yml b/.github/workflows/Tests.yml index 203cdd1..0555ee3 100644 --- a/.github/workflows/Tests.yml +++ b/.github/workflows/Tests.yml @@ -17,7 +17,8 @@ jobs: strategy: matrix: - php: [ '8.0', '8.3' ] + # Changes here might also require changes to .ddev/config.yaml. + php: [ '8.0', '8.4' ] fail-fast: false steps: From 3ded4da56fde5e9ae07c1f453d19f95eb3541798 Mon Sep 17 00:00:00 2001 From: Alex Pott Date: Wed, 13 Aug 2025 16:21:24 +0100 Subject: [PATCH 2/2] Better fix for test fails than previous PR --- .ddev/config.yaml | 2 +- test/Test/WebDriver/ChromeDriverNonW3CTest.php | 1 - test/Test/WebDriver/ChromeDriverTest.php | 5 +++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.ddev/config.yaml b/.ddev/config.yaml index bf8bf5f..d804eec 100644 --- a/.ddev/config.yaml +++ b/.ddev/config.yaml @@ -17,7 +17,7 @@ nodejs_version: "18" corepack_enable: false web_extra_daemons: - name: chromedriver - command: /usr/bin/chromedriver --verbose + command: /usr/bin/chromedriver --port=9515 --verbose directory: /usr/bin - name: geckodriver command: /usr/local/bin/geckodriver -b /usr/bin/firefox diff --git a/test/Test/WebDriver/ChromeDriverNonW3CTest.php b/test/Test/WebDriver/ChromeDriverNonW3CTest.php index 2a63371..9e24220 100644 --- a/test/Test/WebDriver/ChromeDriverNonW3CTest.php +++ b/test/Test/WebDriver/ChromeDriverNonW3CTest.php @@ -32,6 +32,5 @@ class ChromeDriverNonW3CTest extends ChromeDriverTest { protected $w3c = false; - protected $testWebDriverRootUrl = 'http://oldchrome:4444'; } diff --git a/test/Test/WebDriver/ChromeDriverTest.php b/test/Test/WebDriver/ChromeDriverTest.php index a02bc10..3d9bada 100644 --- a/test/Test/WebDriver/ChromeDriverTest.php +++ b/test/Test/WebDriver/ChromeDriverTest.php @@ -35,7 +35,7 @@ */ class ChromeDriverTest extends WebDriverTestBase { - protected $testWebDriverRootUrl = 'http://chrome:4444'; + protected $testWebDriverRootUrl = 'http://localhost:9515'; protected $testWebDriverName = 'chromedriver'; protected $w3c = true; protected $status = null; @@ -71,7 +71,8 @@ protected function setUp(): void public function testStatus() { $this->assertEquals(1, $this->status['ready'], 'Chromedriver is not ready'); - $this->assertEquals('Selenium Grid ready.', $this->status['message'], 'Chromedriver is not ready'); + $this->assertEquals('ChromeDriver ready for new sessions.', $this->status['message'], 'Chromedriver is not ready'); + $this->assertNotEmpty($this->status['os'], 'OS info not detected'); $this->assertSame($this->w3c, $this->session->isW3c()); } }