Skip to content

Commit 7325989

Browse files
committed
Add getComponents test for empty object
1 parent d020f20 commit 7325989

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

tests/Unit/Property/SelectorTest.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -403,6 +403,18 @@ public function setComponentsSetsComponentsProvided(array $components, array $ex
403403
self::assertSame($expectedRepresenation, $representation);
404404
}
405405

406+
/**
407+
* @test
408+
*/
409+
public function getComponentsReturnsEmptyArrayIfNotSet(): void
410+
{
411+
$subject = new Selector();
412+
413+
$result = $subject->getComponents();
414+
415+
self::assertSame([], $result);
416+
}
417+
406418
/**
407419
* @test
408420
*

0 commit comments

Comments
 (0)