Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: fix PHP 8.4 deprecations for implicit nullable #460

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion PHPUnit/Extensions/Selenium2TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ public function prepareSession()
return $this->session;
}

public function run(TestResult $result = NULL): TestResult
public function run(?TestResult $result = NULL): TestResult
{
$this->testId = get_class($this) . '__' . $this->getName();

Expand Down
2 changes: 1 addition & 1 deletion PHPUnit/Extensions/Selenium2TestCase/SessionStrategy.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,5 @@ public function session(array $parameters);

public function notSuccessfulTest();

public function endOfTest(Session $session = NULL);
public function endOfTest(?Session $session = NULL);
}
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public function notSuccessfulTest()
{
}

public function endOfTest(Session $session = NULL)
public function endOfTest(?Session $session = NULL)
{
if ($session !== NULL) {
$session->stop();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function notSuccessfulTest()
$this->lastTestWasNotSuccessful = TRUE;
}

public function endOfTest(Session $session = NULL)
public function endOfTest(?Session $session = NULL)
{
}
}
2 changes: 1 addition & 1 deletion Tests/Selenium2TestCase/Coverage/CookieTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class CookieTest extends BaseTestCase
// this is a dummy URL (returns down coverage data in HTML), but Firefox still sets domain cookie, which is what's needed
protected $coverageScriptUrl = PHPUNIT_TESTSUITE_EXTENSION_SELENIUM_TESTS_URL .'/coverage/dummy.html';

public function run(TestResult $result = NULL): TestResult
public function run(?TestResult $result = NULL): TestResult
{
// make sure code coverage collection is enabled
if ($result === NULL) {
Expand Down