Skip to content

Commit

Permalink
[TASK] Happify phpstan
Browse files Browse the repository at this point in the history
Remove two obsolete exceptions - empty string will
throw in \ReflectionClass by PHP.
  • Loading branch information
lolli42 authored and sbuerk committed Jun 11, 2024
1 parent 359dd58 commit b5ecc8c
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions Classes/Core/BaseTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ abstract class BaseTestCase extends TestCase
* @param bool $callAutoload whether to call any autoload function
*
* @return MockObject&AccessibleObjectInterface&T a mock of `$originalClassName` with access methods added
*
* @throws \InvalidArgumentException
*/
protected function getAccessibleMock(
$originalClassName,
Expand All @@ -51,10 +49,6 @@ protected function getAccessibleMock(
$callOriginalClone = true,
$callAutoload = true
) {
if ($originalClassName === '') {
throw new \InvalidArgumentException('$originalClassName must not be empty.', 1334701880);
}

$mockBuilder = $this->getMockBuilder($this->buildAccessibleProxy($originalClassName))
->setConstructorArgs($arguments)
->setMockClassName($mockClassName);
Expand Down Expand Up @@ -106,10 +100,6 @@ protected function getAccessibleMockForAbstractClass(
$callAutoload = true,
$mockedMethods = []
) {
if ($originalClassName === '') {
throw new \InvalidArgumentException('$originalClassName must not be empty.', 1384268260);
}

return $this->getMockForAbstractClass(
$this->buildAccessibleProxy($originalClassName),
$arguments,
Expand Down

0 comments on commit b5ecc8c

Please sign in to comment.