Added toBeList expectation

This commit is contained in:
Morten Harders
2024-05-21 08:13:20 +02:00
parent 303f4c0113
commit 55f6b5696e
2 changed files with 32 additions and 0 deletions

View File

@ -467,6 +467,18 @@ final class Expectation
return $this;
}
/**
* Asserts that the value is a list.
*
* @return self<TValue>
*/
public function toBeList(string $message = ''): self
{
Assert::assertIsList($this->value, $message);
return $this;
}
/**
* Asserts that the value is of type bool.
*