xref: /PHP-8.2/ext/opcache/tests/preload_enum.phpt (revision b1b0c81e)
1--TEST--
2Enum preloading
3--EXTENSIONS--
4opcache
5--INI--
6opcache.enable=1
7opcache.enable_cli=1
8opcache.optimization_level=-1
9opcache.preload={PWD}/preload_enum.inc
10--SKIPIF--
11<?php
12if (PHP_OS_FAMILY == 'Windows') die('skip Preloading is not supported on Windows');
13--FILE--
14<?php
15
16var_dump(MyEnum::Foo);
17var_dump(MyEnum::Bar);
18
19?>
20--EXPECT--
21enum(MyEnum::Bar)
22enum(MyEnum::Foo)
23enum(MyEnum::Bar)
24