Download src/php/php-src/Zend/tests/assert/expect_010.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 540 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/assert/expect_010.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/Zend/tests/assert/expect_010.phpt
-
curl -L -o expect_010.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/assert/expect_010.phpt
540 Bytes
| --TEST-- | |
| test stack trace is correct from failed exception in extended class (parent implementing constructor) | |
| --INI-- | |
| zend.assertions=1 | |
| assert.exception=1 | |
| --FILE-- | |
| <?php | |
| class One { | |
| public function __construct() { | |
| assert(false); | |
| } | |
| } | |
| class Two extends One {} | |
| new Two(); | |
| ?> | |
| --EXPECTF-- | |
| Fatal error: Uncaught AssertionError: assert(false) in %sexpect_010.php:%d | |
| Stack trace: | |
| #0 %sexpect_010.php(%d): assert(false, 'assert(false)') | |
| #1 %sexpect_010.php(%d): One->__construct() | |
| #2 {main} | |
| thrown in %sexpect_010.php on line %d | |