Download src/php/php-src/ext/phar/tests/017.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 844 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/phar/tests/017.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/ext/phar/tests/017.phpt
-
curl -L -o 017.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/phar/tests/017.phpt
844 Bytes
| --TEST-- | |
| Phar: opendir test - no dir specified at all | |
| --EXTENSIONS-- | |
| phar | |
| --INI-- | |
| phar.require_hash=0 | |
| --FILE-- | |
| $fname = __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.php'; | |
| $pname = 'phar://' . $fname; | |
| $file = "<?php | |
| Phar::mapPhar('hio'); | |
| var_dump(__FILE__); | |
| var_dump(substr(__FILE__, 0, 4) != 'phar'); | |
| __HALT_COMPILER(); ?>"; | |
| $files = array(); | |
| $files['a'] = 'abc'; | |
| include 'files/phar_test.inc'; | |
| include $pname; | |
| $dir = opendir('phar://hio'); | |
| --CLEAN-- | |
| unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); | |
| --EXPECTF-- | |
| string(%d) "%s017.phar.php" | |
| bool(true) | |
| Warning: opendir(phar://hio): Failed to open directory: phar error: no directory in "phar://hio", must have at least phar://hio/ for root directory (always use full path to a new phar) | |
| phar url "phar://hio" is unknown in %s017.php on line %d | |