Skip to content

Commit 5b2587c

Browse files
authored
[4.x] resolve PHPUnit Notices (#72)
1 parent 3c49472 commit 5b2587c

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

‎Tests/HttpTest.php‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use Laminas\Diactoros\Request;
1515
use PHPUnit\Framework\MockObject\MockObject;
1616
use PHPUnit\Framework\TestCase;
17+
use PHPUnit\Framework\Attributes\AllowMockObjectsWithoutExpectations;
1718

1819
/**
1920
* Test class for Joomla\Http\Http.
@@ -61,6 +62,7 @@ protected function setUp(): void
6162
*
6263
* @covers Joomla\Http\Http
6364
*/
65+
#[AllowMockObjectsWithoutExpectations]
6466
public function testConstructorDisallowsNonArrayObjects()
6567
{
6668
$this->expectException(\InvalidArgumentException::class);
@@ -73,6 +75,7 @@ public function testConstructorDisallowsNonArrayObjects()
7375
*
7476
* @covers Joomla\Http\Http
7577
*/
78+
#[AllowMockObjectsWithoutExpectations]
7679
public function testOptionManagement()
7780
{
7881
$this->object->setOption('testKey', 'testValue');
@@ -201,6 +204,7 @@ public function testGetWithUri()
201204
*
202205
* @covers Joomla\Http\Http
203206
*/
207+
#[AllowMockObjectsWithoutExpectations]
204208
public function testGetWithInvalidUrl()
205209
{
206210
$this->expectException(\InvalidArgumentException::class);

0 commit comments

Comments
 (0)