File manager - Edit - /opt/cpanel/ea-php74/root/usr/share/tests/pecl/mongodb/tests/exception/commandexception-getresultdocument-001.phpt
Back
--TEST-- MongoDB\Driver\Exception\CommandException::getResultDocument() --FILE-- <?php $exception = new MongoDB\Driver\Exception\CommandException(); $resultDocument = (object) ['x' => 1]; $reflection = new ReflectionClass($exception); $resultDocumentProperty = $reflection->getProperty('resultDocument'); $resultDocumentProperty->setAccessible(true); $resultDocumentProperty->setValue($exception, $resultDocument); var_dump($resultDocument === $exception->getResultDocument()); ?> ===DONE=== <?php exit(0); ?> --EXPECT-- bool(true) ===DONE===
| ver. 1.4 |
Github
|
.
| PHP 8.2.30 | Generation time: 0 |
proxy
|
phpinfo
|
Settings