diff options
-rw-r--r-- | tests/lib/TestCase.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/lib/TestCase.php b/tests/lib/TestCase.php index aa2c720d830..69cf2a39792 100644 --- a/tests/lib/TestCase.php +++ b/tests/lib/TestCase.php @@ -226,7 +226,11 @@ abstract class TestCase extends \PHPUnit\Framework\TestCase { $property->setValue($object, array_pop($parameters)); } - return $property->getValue($object); + if (is_object($object)) { + return $property->getValue($object); + } + + return $property->getValue(); } return false; |