Skip to content

Commit 5254a57

Browse files
committed
Update PHPUnit tests to be PHP 8.4 compatible
1 parent 6507fb3 commit 5254a57

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

tests/Twilio/Holodeck.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ class Holodeck implements Client {
1313

1414
public function request(string $method, string $url,
1515
array $params = [], array $data = [], array $headers = [],
16-
string $user = null, string $password = null,
17-
int $timeout = null): Response {
16+
?string $user = null, ?string $password = null,
17+
?int $timeout = null): Response {
1818
$this->requests[] = new Request($method, $url, $params, $data, $headers, $user, $password);
1919
if (\count($this->responses) === 0) {
2020
return new Response(404, null, null);

tests/Twilio/Request.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class Request {
1414

1515
public function __construct(string $method, string $url,
1616
?array $params = [], array $data = [], array $headers = [],
17-
string $user = null, string $password = null) {
17+
?string $user = null, ?string $password = null) {
1818
$this->method = $method;
1919
$this->url = $url;
2020
$this->params = $params;

tests/Twilio/Unit/ValuesTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ private function testPassingValues(
9494
int $intVal = Values::INT_NONE,
9595
bool $boolVal = Values::BOOL_NONE,
9696
string $stringVal = Values::NONE,
97-
\DateTime $dateTimeVal = null
97+
?\DateTime $dateTimeVal = null
9898
): array
9999
{
100100
$arr = [];

0 commit comments

Comments
 (0)