Download src/php/php-src/Zend/tests/assert/expect_008.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 624 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/assert/expect_008.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/Zend/tests/assert/expect_008.phpt
-
curl -L -o expect_008.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/Zend/tests/assert/expect_008.phpt
624 Bytes
| --TEST-- | |
| test disabled expectations have no ill side effects | |
| --INI-- | |
| zend.assertions=0 | |
| assert.exception=1 | |
| --FILE-- | |
| class One { | |
| public function __construct() { | |
| assert($this || 0); | |
| } | |
| } | |
| class Two extends One {} | |
| class OdEar extends AssertionError {} | |
| function blah(){ return 1; } | |
| $variable = 1; | |
| assert(true, "constant message"); | |
| assert(($variable && $variable) || php_sapi_name(), new OdEar("constant message")); | |
| assert(false); | |
| assert(blah(), blah()); | |
| new Two(); | |
| new Two(); | |
| new Two(); | |
| assert (blah() || blah() || blah(), blah() || blah() || blah() || blah()); | |
| var_dump(true); | |
| --EXPECT-- | |
| bool(true) | |