mirror of
https://github.com/php/php-src.git
synced 2024-12-01 05:43:38 +08:00
- Add new test
This commit is contained in:
parent
aa87beaded
commit
5506e024d4
3
Zend/tests/ns_069.inc
Normal file
3
Zend/tests/ns_069.inc
Normal file
@ -0,0 +1,3 @@
|
||||
<?php
|
||||
|
||||
var_dump((binary)__NAMESPACE__);
|
24
Zend/tests/ns_069.phpt
Normal file
24
Zend/tests/ns_069.phpt
Normal file
@ -0,0 +1,24 @@
|
||||
--TEST--
|
||||
069: Include inside namespaced method
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
namespace foo;
|
||||
|
||||
class Test {
|
||||
static function f() {
|
||||
var_dump((binary)__NAMESPACE__);
|
||||
include __DIR__ . '/ns_069.inc';
|
||||
var_dump((binary)__NAMESPACE__);
|
||||
}
|
||||
}
|
||||
|
||||
Test::f();
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECT--
|
||||
string(3) "foo"
|
||||
string(0) ""
|
||||
string(3) "foo"
|
||||
===DONE===
|
Loading…
Reference in New Issue
Block a user