Remove most of the `===DONE===` tags and its variations.
Keep `===DONE===` if the test output otherwise becomes empty.
Closes GH-4872.
//Note: No error conditions relating to passing arguments can be tested
// because these are not functions but statements, it will result in syntax error.
?>
-===DONE===
--EXPECTF--
*** Testing unset(), empty() & isset() with scalar variables ***
-- Iteration 1 --
bool(false)
bool(true)
int(10)
-===DONE===
}
?>
-===DONE===
--EXPECT--
Hello World!
===NONE===
Method NoneTest::__toString() must return a string value
===THROW===
This is an error!
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
Objects returned by array_iterator::getIterator() must be traversable or implement interface Iterator
-===DONE===
}
?>
-===DONE===
--EXPECT--
a-s-d-d-/-?+
-===DONE===
var_dump(class_exists('NotExistingClass'));
?>
-===DONE===
--EXPECT--
{closure}(NotExistingClass)
bool(false)
{closure}(NotExistingClass), done
bool(false)
-===DONE===
$p->callTwo();
$p->callThree();
?>
-===DONE===
--EXPECT--
Caught: NONE
Caught: NONE
Caught: NONE
-===DONE===
?>
-===DONE===
--EXPECT--
global_func
foo::foo_func
-===DONE===
$b->test();
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
-===DONE===
$y[0] = 'hello';
A::{$y[0]}();
?>
-===DONE===
--EXPECTF--
Hello World
-===DONE===
var_dump(get_object_vars(new Child));
?>
-===DONE===
--EXPECT--
Base::__construct
array(3) {
["Foo"]=>
int(1)
}
-===DONE===
var_dump(ClassC::$prop);
?>
-===DONE===
--EXPECT--
===INIT===
string(1) "A"
string(2) "A2"
string(2) "C2"
string(2) "C2"
-===DONE===
var_dump($y->z->x = 6);
?>
-===DONE===
--EXPECT--
object(ObjectOne)#2 (1) {
["x"]=>
int(5)
Overloaded::__get(z)
int(6)
-===DONE===
unset($bar);
?>
-===DONE===
--EXPECT--
Foo::__construct
Caught exception!
-===DONE===
var_dump(get_class_vars('Test'));
?>
-===DONE===
--EXPECT--
array(2) {
["empty"]=>
}
}
}
-===DONE===
var_dump($db);
?>
-===DONE===
--EXPECTF--
Warning: Undefined variable: db in %s on line %d
NULL
["y"]=>
string(1) "y"
}
-===DONE===
echo "\n";
?>
-===DONE===
--EXPECT--
page_show
-===DONE===
haricow();
haricow();
?>
-===DONE===
--EXPECT--
string(3) "one"
string(3) "one"
-===DONE===
}
?>
-===DONE===
--EXPECT--
Caught
-===DONE===
$f = fopen("/tmp/blah", "r");
?>
-===DONE===
--EXPECTF--
fopen(/tmp/blah): failed to open stream: %s (2) in %s:%d
Warning: fopen(/tmp/blah): failed to open stream: %s in %s on line %d
-===DONE===
}
?>
===DONE===
-<?php exit(0); ?>
--EXPECTF--
{closure}(Test1,1)
Caught: Test1::__construct
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECTF--
Warning: Undefined variable: nonesuchvar in %s on line %d
array_walk() expects parameter 2 to be a valid callback, first array member is not a valid class name or object
-===DONE===
}
?>
-===DONE===
--EXPECT--
Caught
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test::offsetSet(-1, 123)
CAUGHT
-===DONE===
var_dump($x->doSomethingStatic(1));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===A===
TestB::doSomething(1)
TestB::doSomethingStatic(1)
TestA::doSomethingStatic(2)
int(1)
-===DONE===
var_dump($B);
?>
-===DONE===
--EXPECTF--
object(B)#%d (1) {
["value":protected]=>
["value":protected]=>
string(1) "C"
}
-===DONE===
var_dump($obj);
?>
-===DONE===
--EXPECTF--
string(3) "bar"
string(3) "bar"
}
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing restore_error_handler() : error bug #46196 ***
NULL
bool(true)
NULL
-===DONE===
$b = new B();
$b->A();
?>
-===DONE===
--EXPECT--
B::__construct
A::__construct
B::A
A::A
-===DONE===
$test = new Test();
?>
-===DONE===
--EXPECT--
array (
1 => 'first',
3 => 'third',
4 => 4,
)
-===DONE===
echo 2.2250738585072012e-308, "\n";
?>
-==DONE==
--EXPECT--
2.2250738585072014E-308
-==DONE==
var_dump($str[10] = "");
var_dump($str);
?>
-==DONE==
--EXPECTF--
Warning: Cannot assign an empty string to a string offset in %s on line %d
NULL
Warning: Cannot assign an empty string to a string offset in %s on line %d
NULL
string(3) "abc"
-==DONE==
EOT;
?>
-===DONE===
--EXPECT--
foo
c
foo
c
-===DONE===
var_dump(parse_ini_string($ini, false, INI_SCANNER_RAW));
?>
-===DONE===
--EXPECT--
array(7) {
[1]=>
[7]=>
string(7) "foo"bar"
}
-===DONE===
$foo = new Foo45;
var_dump($foo->a);
?>
-===DONE===
--EXPECT--
bool(true)
string(10) "Some value"
-===DONE===
echo "Done\n";
?>
-===DONE===
--EXPECTF--
#0 boo() called at [%s:%d]
#1 bar() called at [%s:%d]
#2 foo() called at [%s(%d) : eval()'d code:1]
#3 eval() called at [%s:%d]
Done
-===DONE===
var_dump($a);
?>
-===DONE===
--EXPECTF--
object(Closure)#%d (1) {
["static"]=>
*RECURSION*
}
}
-===DONE===
?>
-===DONE===
--EXPECT--
Access public static function OK
Access public static function with different case OK
Access proteced instance method of parent object through "self::" to parent method OK
MagicCall __call instance method __call,nonExistentMethod, OK
MagicCall __callStatic static method __callStatic,nonExistentMethod, OK
-===DONE===
echo "OK\n";
?>
-===DONE===
--EXPECT--
Cannot access privateInstance method statically
Cannot access privateInstance method statically with colon scheme
Function scope cannot closure over private instance method
Access private instance method of parent object through "self::" to parent method
OK
-===DONE===
}
var_dump(function_exists('C::f'));
?>
-===Done===
--EXPECT--
*** Testing function_exists() : basic functionality ***
Internal function: bool(true)
Case sensitivity: bool(true)
Non existent function: bool(false)
Method: bool(false)
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing get_defined_functions() : basic functionality ***
TEST PASSED
-===Done===
include __DIR__ . '/test1.php';
include __DIR__ . '/test2.php';
?>
-==DONE==
--CLEAN--
<?php
unlink(__DIR__ . '/test1.php');
--EXPECT--
testint(73)
test2int(74)
-==DONE==
<?php
define ('__COMPILER_HALT_OFFSET__', 1);
?>
-==DONE==
--EXPECTF--
Notice: Constant __COMPILER_HALT_OFFSET__ already defined in %s on line %d
-==DONE==
echo ChildClass2::testClassConst() . "\n";
echo ChildClass2::testStaticFunction() . "\n";
?>
-==DONE==
--EXPECT--
TestClassStatic
TestClassConst
TestClassStatic
TestClassConst
TestClassFunction
-==DONE==
echo $childClass2->testClassConst() . "\n";
echo $childClass2->testStaticFunction() . "\n";
?>
-==DONE==
--EXPECT--
TestClassStatic
TestClassConst
TestClassStatic
TestClassConst
TestClassFunction
-==DONE==
echo get_class($testClass) . "\n";
echo get_class($childClass) . "\n";
?>
-==DONE==
--EXPECT--
TestClass
ChildClass
-==DONE==
echo TestClass::getClassName() . "\n";
echo ChildClass::getClassName() . "\n";
?>
-==DONE==
--EXPECT--
TestClass
ChildClass
-==DONE==
TestA::test();
?>
-==DONE==
--EXPECT--
TestA
TestB
TestC
TestBB
TestA
-==DONE==
echo "via B:\n";
B::myCatch();
?>
-==DONE==
--EXPECT--
via A:
A
B
B
B
-==DONE==
$o->a = "b";
echo $o->a;
?>
-==DONE==
--EXPECT--
TestChild
TestChild
TestChild
-==DONE==
echo A::test(B::test(C::test(D::test())))."\n";
?>
-==DONE==
--EXPECT--
D
C
B
A
-==DONE==
$y->identify();
$z->identify();
?>
-===DONE===
--EXPECTF--
object(Foo)#%d (1) {
["instanceId":"Singleton":private]=>
["instanceId":"Singleton":private]=>
int(2)
}
-===DONE===
echo '\'hello';
?>
-===DONE===
--EXPECT--
'hello
-===DONE===
$s = "\95\"; // 0x95+0x5c in script, not somewhere else "
printf("%x:%x\n", ord($s[0]), ord($s[1]));
?>
-===DONE===
--EXPECT--
95:5c
-===DONE===
<?php
print "Hello World\n";
?>
-===DONE===
--EXPECT--
Hello World
-===DONE===
Test::f();
?>
-===DONE===
--EXPECT--
string(3) "foo"
string(0) ""
string(3) "foo"
-===DONE===
var_dump(is_null($o));
?>
-===DONE===
--EXPECT--
bool(false)
bool(true)
bool(false)
bool(true)
bool(false)
-===DONE===
var_dump($a);
?>
-==DONE==
--EXPECT--
object(A)#1 (1) {
["foo"]=>
}
}
}
-==DONE==
echo "Failed: $f\n";
}
?>
-===DONE===
--CLEAN--
<?php
$fl = __DIR__ . DIRECTORY_SEPARATOR . 'compare_binary_operands_temp.php';
?>
--EXPECT--
Failed: 0
-===DONE===
foo();
?>
-===DONE===
--EXPECT--
int(1)
int(2)
int(3)
-===DONE===
foo();
?>
-===DONE===
--EXPECT--
int(1)
int(2)
int(3)
-===DONE===
}
?>
-===DONE===
--EXPECT--
Caught
-===DONE===
}
?>
-===DONE===
--EXPECT--
Caught
-===DONE===
MyObject::test();
?>
-===DONE===
--EXPECT--
Caught
-===DONE===
foo();
?>
-===DONE===
--EXPECT--
try
finally
-===DONE===
foo();
?>
-===DONE===
--EXPECT--
try
finally
-===DONE===
foo();
?>
-===DONE===
--EXPECT--
int(1)
int(2)
int(3)
-===DONE===
echo "outer catch\n";
}
?>
-===DONE===
--EXPECT--
finally
outer catch
-===DONE===
foo();
?>
-===DONE===
--EXPECT--
finally1
catch2
finally2
-===DONE===
var_dump(new C);
?>
-===DONE===
--EXPECT--
object(A)#2 (0) {
}
}
object(C)#2 (0) {
}
-===DONE===
var_dump(new B);
?>
-===DONE===
--EXPECT--
object(A)#2 (0) {
}
}
object(B)#2 (0) {
}
-===DONE===
var_dump(new B);
?>
-===DONE===
--EXPECT--
object(A)#2 (0) {
}
}
object(B)#2 (0) {
}
-===DONE===
var_dump(new B);
?>
-===DONE===
--EXPECT--
object(A)#2 (0) {
}
}
object(B)#2 (0) {
}
-===DONE===
var_dump(new B);
?>
-===DONE===
--EXPECT--
object(A)#2 (0) {
}
}
object(B)#2 (0) {
}
-===DONE===
<?php
var_dump(bcpow('1', '1.1', 2));
?>
-===DONE===
--EXPECTF--
Warning: bcpow(): non-zero scale in exponent in %s on line %d
string(4) "1.00"
-===DONE===
<?php
var_dump(bcpow('0', '9223372036854775808', 2));
?>
-===DONE===
--EXPECTF--
Warning: bcpow(): exponent too large in %s on line %d
string(4) "1.00"
-===DONE===
<?php
var_dump(bcmul('0.3', '0.2', 4));
?>
-===DONE===
--EXPECT--
string(6) "0.0600"
-===DONE===
var_dump(bcpowmod('4', '4', '3', 1));
var_dump(bcpowmod('3234', '32345', '22345', 1));
?>
-===DONE===
--EXPECT--
string(3) "1.0"
string(7) "17334.0"
-===DONE===
var_dump(bcadd('-0.0', '-0.0', 1));
var_dump(bccomp('-0.0', '0', 1));
?>
-===DONE===
--EXPECT--
string(3) "0.0"
int(0)
-===DONE===
var_dump(bcpowmod(5, 0, 1));
var_dump(bcpowmod(5, 0, 1, 3));
?>
-===DONE===
--EXPECT--
string(1) "0"
string(5) "0.000"
-===DONE===
var_dump(bcpowmod('4.1', '4', '3', 3));
var_dump(bcpowmod('4', '4', '3.1', 3));
?>
-===DONE===
--EXPECTF--
Warning: bcpowmod(): non-zero scale in base in %s on line %d
string(5) "1.000"
Warning: bcpowmod(): non-zero scale in modulus in %s on line %d
string(5) "1.000"
-===DONE===
'bcsqrt: ', bcsqrt('4', 5), PHP_EOL,
'bcsub: ', bcsub('2', '1', 5), PHP_EOL;
?>
-===DONE===
--EXPECT--
bcadd: 3.00000
bcdiv: 2.00000
bcpowmod: 2.00000
bcsqrt: 2.00000
bcsub: 1.00000
-===DONE===
'bcsqrt: ', bcsqrt('4'), PHP_EOL,
'bcsub: ', bcsub('2', '1'), PHP_EOL;
?>
-===DONE===
--EXPECT--
bcadd: 3.00000
bcdiv: 2.00000
bcpowmod: 2.00000
bcsqrt: 2.00000
bcsub: 1.00000
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECT--
normal year 5000
e020faf9f8e920e4
e020e0e120e4e0
e020e0ece5ec20e4e0
-===DONE===
var_dump(com_load_typelib($typelib));
var_dump(com_load_typelib($typelib));
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
?>
--EXPECT--
bool(true)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
?>
--EXPECT--
bool(true)
-===DONE===
var_dump(unserialize($string));
}
?>
-===DONE===
--EXPECTF--
Exception: Serialization of 'com' is not allowed
Exception: Serialization of 'dotnet' is not allowed
Notice: unserialize(): Error at offset 17 of 18 bytes in %s on line %d
bool(false)
-===DONE===
exec($command, $output, $status);
var_dump($output, $status);
?>
-===DONE===
--EXPECT--
array(0) {
}
int(0)
-===DONE===
$root = dirname(array_change_key_case($_SERVER, CASE_UPPER)['COMSPEC']);
com_load_typelib("$root\activeds.tlb");
?>
-===DONE===
--EXPECTF--
Warning: com_load_typelib(): Type library constant ADSTYPE_INVALID is already defined in %s on line %d
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alnum() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alnum() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alnum() : usage variations ***
character code 48 is alpha numeric
character code 120 is alpha numeric
character code 121 is alpha numeric
character code 122 is alpha numeric
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alnum() : usage variations ***
-- Iteration 23 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alnum() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alpha() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alpha() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alpha() : usage variations ***
character code 65 is alphabetic
character code 120 is alphabetic
character code 121 is alphabetic
character code 122 is alphabetic
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alpha() : usage variations ***
-- Iteration 23 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_alpha() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_cntrl() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_cntrl() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_cntrl() : usage variations ***
character code 0 is control character
character code 30 is control character
character code 31 is control character
character code 127 is control character
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_cntrl() : usage variations ***
-- Iteration 30 --
bool(true)
-===DONE===
}
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_cntrl() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_digit() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_digit() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_digit() : usage variations ***
character code 48 is a numeric digit
character code 55 is a numeric digit
character code 56 is a numeric digit
character code 57 is a numeric digit
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_digit() : usage variations ***
-- Iteration 31 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_digit() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_graph() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_graph() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_graph() : usage variations ***
character code 33 is a printable character
character code 124 is a printable character
character code 125 is a printable character
character code 126 is a printable character
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_graph() : usage variations ***
-- Iteration 28 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_graph() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_lower() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_lower() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_lower() : usage variations ***
character code 97 is a lower case character
character code 120 is a lower case character
character code 121 is a lower case character
character code 122 is a lower case character
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_lower() : usage variations ***
-- Iteration 26 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_lower() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_print() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_print() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_print() : usage variations ***
character code 32 is a printable character
character code 124 is a printable character
character code 125 is a printable character
character code 126 is a printable character
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_print() : usage variations ***
-- Iteration 23 --
bool(false)
-===DONE===
}
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_print() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_punct() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_punct() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_punct() : usage variations ***
character code 33 is punctuation
character code 124 is punctuation
character code 125 is punctuation
character code 126 is punctuation
-===DONE===
};
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_punct() : usage variations ***
-- Iteration 26 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_punct() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_space() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_space() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
}
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_space() : usage variations ***
character code 9 is a space character
character code 12 is a space character
character code 13 is a space character
character code 32 is a space character
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_space() : usage variations ***
-- Iteration 26 --
bool(true)
-===DONE===
}
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_space() : usage variations ***
bool(true)
-- Iteration 6 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_upper() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_upper() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_upper() : usage variations ***
character code 65 is a uppercase character
character code 88 is a uppercase character
character code 89 is a uppercase character
character code 90 is a uppercase character
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_upper() : usage variations ***
-- Iteration 26 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_upper() : usage variations ***
bool(true)
-- Iteration 4 --
bool(true)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_xdigit() : basic functionality ***
bool(true)
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_xdigit() : usage variations ***
-- Iteration 25 --
bool(false)
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_xdigit() : usage variations ***
character code 48 is a hexadecimal 'digit'
character code 100 is a hexadecimal 'digit'
character code 101 is a hexadecimal 'digit'
character code 102 is a hexadecimal 'digit'
-===DONE===
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_xdigit() : usage variations ***
-- Iteration 26 --
bool(false)
-===DONE===
}
setlocale(LC_CTYPE, $orig);
?>
-===DONE===
--EXPECT--
*** Testing ctype_xdigit() : usage variations ***
bool(true)
bool(true)
bool(true)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php @unlink(__DIR__ . '/bug54798.tmp'); ?>
--EXPECTF--
%aOk for CURLOPT_WRITEHEADER
%aOk for CURLOPT_FILE
%aOk for CURLOPT_INFILE
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php @unlink(__DIR__ . '/bug54798.tmp'); ?>
--EXPECTF--
Hello World!Ok for CURLOPT_FILE
%AOk for CURLOPT_INFILE
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl sending through GET an POST ***
string(203) "array(2) {
string(8) "John Doe"
}
"
-===DONE===
curl_exec($c);
var_dump(curl_getinfo($c, CURLINFO_RESPONSE_CODE));
?>
-===DONE===
--EXPECTF--
TEST
bool(true)
bool(true)
int(30%d)
-===DONE===
curl_exec($ch);
curl_close($ch);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/body.tmp');
}
array(0) {
}
-===DONE===
var_dump(curl_exec($ch));
curl_close($ch);
?>
-===DONE===
--EXPECTF--
bool(true)
string(%d) "АБВ.txt|application/octet-stream"
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/АБВ.txt');
echo "curl_exec returned false";
}
?>
-===DONE===
--EXPECT--
*** Testing curl_exec() : basic functionality ***
string(25) "Hello World!
Hello World!"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); ***
string(25) "Hello World!
Hello World!"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl sending through GET an POST ***
string(208) "array(2) {
string(8) "John Doe"
}
"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl setting referer ***
string(19) "http://www.refer.er"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl with user agent ***
string(9) "cURL phpt"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl with cookie ***
string(3) "bar"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl with HTTP/1.0 ***
string(8) "HTTP/1.0"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl with HTTP/1.1 ***
string(8) "HTTP/1.1"
-===DONE===
$ch = curl_init();
var_dump($ch);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (curl)
-===DONE===
$ch = curl_init($url);
var_dump($url == curl_getinfo($ch, CURLINFO_EFFECTIVE_URL));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
$info = curl_getinfo($ch);
var_dump($info);
?>
-===DONE===
--EXPECTF--
array(2%d) {
["url"]=>
["redirect_time"]=>
float(0)
}
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl_exec() : basic functionality ***
string(75) "Hello World!
Hello World!Hello World!
Hello World!Hello World!
Hello World!"
-===DONE===
var_dump($url == $info);
curl_close($ch);
?>
-===DONE===
--EXPECT--
Hello World!
Hello World!bool(true)
-===DONE===
var_dump(curl_getinfo($ch, CURLINFO_HTTP_CODE));
curl_close($ch);
?>
-===DONE===
--EXPECT--
Hello World!
Hello World!int(200)
-===DONE===
var_dump(curl_getinfo($ch, CURLINFO_CONTENT_TYPE));
curl_close($ch);
?>
-===DONE===
--EXPECT--
string(24) "text/plain;charset=utf-8"
-===DONE===
var_dump(CURL_HTTP_VERSION_1_1 === curl_getinfo($ch, CURLINFO_HTTP_VERSION));
curl_close($ch);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
var_dump(curl_getinfo($ch, CURLINFO_SCHEME));
curl_close($ch);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
string(4) "HTTP"
-===DONE===
curl_close($ch);
var_dump($ch);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (Unknown)
-===DONE===
var_dump(curl_getinfo($ch) === curl_getinfo($ch2));
?>
-===DONE===
--EXPECT--
*** Testing curl_copy_handle(): basic ***
bool(true)
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl copy handle with simple GET ***
string(106) "array(2) {
array(0) {
}
"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl copy handle with simple POST ***
string(163) "array(1) {
string(8) "John Doe"
}
"
-===DONE===
var_dump( $curl_content_copy );
?>
-===DONE===
--EXPECT--
*** Test curl_copy_handle() after exec() ***
string(106) "array(2) {
array(0) {
}
"
-===DONE===
var_dump( $curl_content_copy );
?>
-===DONE===
--EXPECT--
*** Test curl_copy_handle() after exec() with POST ***
string(163) "array(1) {
string(8) "John Doe"
}
"
-===DONE===
curl_close($copy);
?>
-===DONE===
--EXPECT--
*** Testing curl copy handle with User Agent ***
string(9) "cURL phpt"
string(9) "cURL phpt"
-===DONE===
var_dump( $curl_content );
?>
-===DONE===
--EXPECT--
*** Testing curl copy handle with simple POST using array as arguments ***
string(163) "array(1) {
string(8) "John Doe"
}
"
-===DONE===
var_dump(curl_getinfo($ch) === curl_getinfo($ch2));
?>
-===DONE===
--EXPECT--
*** Testing curl_copy_handle(): basic ***
bool(false)
-===DONE===
curl_setopt($ch2, CURLOPT_URL, 'http://www.bar.com/');
var_dump(curl_getinfo($ch) === curl_getinfo($ch2));
?>
-===DONE===
--EXPECT--
*** Testing curl_copy_handle(): add options after copy ***
bool(true)
bool(false)
bool(true)
bool(false)
-===DONE===
var_dump(curl_exec($ch2));
curl_close($ch2);
?>
-===DONE===
--EXPECTF--
bool(true)
string(%d) "АБВ.txt|application/octet-stream"
string(%d) "АБВ.txt|application/octet-stream"
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/АБВ.txt');
var_dump(curl_exec($ch));
curl_close($ch);
?>
-===DONE===
--EXPECT--
bool(true)
string(21) "i-love-php|text/plain"
-===DONE===
curl_close ( $ch );
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
curl_multi_close($ch);
var_dump($ch);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (Unknown)
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECTF--
resource(%d) of type (curl_multi)
NULL
resource(%d) of type (Unknown)
curl_multi_close(): supplied resource is not a valid cURL Multi Handle resource
-===DONE===
curl_multi_close($mh);
var_dump($mh);
?>
-===DONE===
--EXPECTF--
*** Testing curl_multi_init(void); ***
resource(%d) of type (curl_multi)
resource(%d) of type (Unknown)
-===DONE===
curl_close($ch);
curl_multi_close($cmh);
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
curl_multi_close($mh);
?>
-===DONE===
--EXPECTF--
%r(0|-1)%r
-===DONE===
?>
-===DONE===
--EXPECT--
testtest
-===DONE===
$sOutput = file_get_contents($sWriteFile);
var_dump($sOutput);
?>
-===DONE===
--CLEAN--
<?php
$sFileBase = __DIR__.DIRECTORY_SEPARATOR.'curl_opt_CURLOPT_READFUNCTION';
?>
--EXPECT--
string(27) "custom:contents of tempfile"
-===DONE===
curl_version(CURLVERSION_NOW);
curl_version(0);
?>
-===DONE===
--EXPECTF--
Deprecated: curl_version(): the $version parameter is deprecated in %s on line %d
Warning: curl_version(): $version argument ignored in %s on line %d
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing clone on DateTime objects ***
object(DateTimeZone)#%d (2) {
string(3) "GMT"
}
TEST PASSED : Objects equal but not indetical
-===DONE===
var_dump($d2_clone);
?>
-===DONE===
--EXPECTF--
*** Testing clone on objects whoose class derived from DateTimeZone class ***
object(DateTimeZoneExt1)#%d (4) {
["timezone"]=>
string(13) "Europe/London"
}
-===DONE===
$d2_clone = clone $d1_clone;
var_dump($d2_clone);
?>
-===DONE===
--EXPECTF--
*** Testing clone on DateTime objects ***
["timezone"]=>
string(13) "Europe/London"
}
-===DONE===
var_dump( $d1_clone->getName() );
?>
-===DONE===
--EXPECT--
*** Testing clone of objects derived from DateTimeZone class with __clone magic method***
-- DateTimeExt1 __clone magic method called --
string(16) "America/New_York"
-===DONE===
var_dump($obj3 == $obj4);
?>
-===DONE===
--EXPECT--
Simple test for DateTimeZone compare object handler
bool(false)
bool(false)
bool(false)
-===DONE===
var_dump( new DateTimeZone("America/Los_Angeles") );
?>
-===DONE===
--EXPECTF--
*** Testing new DateTimeZone() : basic functionality ***
object(DateTimeZone)#%d (2) {
["timezone"]=>
string(19) "America/Los_Angeles"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing DateTimeZone() : error conditions ***
-- Testing new DateTimeZone() with more than expected no. of arguments --
DateTimeZone::__construct() expects exactly 1 parameter, 2 given
-===DONE===
echo $d . "\n";
?>
-===DONE===
--EXPECT--
*** Testing basic DateTimeZone inheritance() ***
-- Invoke __toString --
America/Los_Angeles
-===DONE===
var_dump( $tz3->getName() );
?>
-===DONE===
--EXPECT--
*** Testing DateTimeZone::getName() : basic functionality ***
string(13) "Europe/London"
string(16) "America/New_York"
string(19) "America/Los_Angeles"
-===DONE===
var_dump( $tz3->getOffset($date) );
?>
-===DONE===
--EXPECTF--
*** Testing DateTimeZone::getOffset() : basic functionality ***
%rint\(0\)|int\(3600\)%r
%rint\(-18000\)|int\(-14400\)%r
%rint\(-28800\)|int\(-25200\)%r
-===DONE===
var_dump( $tran[6] );
?>
-===DONE===
--EXPECT--
*** Testing DateTimeZone::getTransitions() : basic functionality ***
["abbr"]=>
string(3) "BST"
}
-===DONE===
var_dump( $abbr["acst"] );
?>
-===DONE===
--EXPECTF--
*** Testing DateTimeZone::listAbbreviations() : basic functionality ***
string(5) "array"
string(20) "Australia/Yancowinna"
}
}
-===DONE===
var_dump(in_array("UTC", $zones));
?>
-===DONE===
--EXPECT--
*** Testing DateTimeZone::listIdentifiers() : basic functionality ***
Check return tpe is ARRAY
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump( $tz2->getName() );
?>
-===DONE===
--EXPECTF--
object(DateTimeZone)#%d (2) {
["timezone_type"]=>
string(6) "+01:00"
}
string(6) "+01:00"
-===DONE===
var_dump( $tz2->getName() );
?>
-===DONE===
--EXPECTF--
object(DateTimeZone)#%d (2) {
["timezone_type"]=>
string(3) "EST"
}
string(3) "EST"
-===DONE===
var_dump( $tz2->getName() );
?>
-===DONE===
--EXPECT--
object(DateTimeZone)#1 (2) {
["timezone_type"]=>
string(16) "America/New_York"
}
string(16) "America/New_York"
-===DONE===
$constants = $class->getConstants();
var_dump($constants);
?>
-===DONE===
--EXPECTF--
*** Verify DateTimeZone class ***
Verify DateTimeZone class registered OK
["PER_COUNTRY"]=>
int(4096)
}
-===DONE===
echo "Clone: " . $clone->format("H:i:s") . "\n";
?>
-===DONE===
--EXPECT--
*** Testing clone on DateTime objects ***
Original: 22:41:50
Clone: 14:25:41
-===DONE===
$d2_clone = clone $d2;
var_dump($d2_clone);
?>
-===DONE===
--EXPECTF--
*** Testing clone on objects whoose class derived from DateTime class ***
object(DateTimeExt1)#%d (5) {
["timezone"]=>
string(3) "GMT"
}
-===DONE===
$d2_clone = clone $d1_clone;
var_dump($d2_clone);
?>
-===DONE===
--EXPECTF--
*** Testing clone on DateTime objects ***
["timezone"]=>
string(3) "GMT"
}
-===DONE===
var_dump( $d1_clone->format( "m.d.y") );
?>
-===DONE===
--EXPECT--
*** Testing clone of objects derived from DateTime class with __clone magic method***
-- DateTimeExt1 __clone magic method called --
string(8) "02.03.09"
-===DONE===
var_dump($obj1 == $obj3);
var_dump($obj1 == $obj4);
?>
-===DONE===
--EXPECT--
Simple test for DateTime compare object handler
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump( new DateTime("2005-07-14 22:30:41 GMT") );
?>
-===DONE===
--EXPECTF--
*** Testing new DateTime() : basic functionality ***
object(DateTime)#%d (3) {
["timezone"]=>
string(3) "GMT"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing date_create() : error conditions ***
-- Testing new DateTime() with more than expected no. of arguments --
DateTime::__construct() expects at most 2 parameters, 3 given
-===DONE===
echo $d . "\n";
?>
-===DONE===
--EXPECT--
*** Testing basic DateTime inheritance() ***
-- Invoke __toString again --
July 2, 1963, 10:45:30 am
-===DONE===
echo $d->format("F j, Y, g:i:s a") . "\n";
?>
-===DONE===
--EXPECT--
*** Testing new DateTime() : with user space __construct magic method ***
May 1, 1967, 10:30:41 pm
-===DONE===
echo $d->format() . "\n";
?>
-===DONE===
--EXPECT--
*** Testing new DateTime() : with user format() method ***
May 1, 1967, 10:30:41 pm
-===DONE===
echo "createFromFormat method: " . $fromFormat->format("D., M. j, Y g:iA") . "\n";
?>
-===DONE===
--EXPECT--
*** Testing clone on DateTime objects ***
Format method: Thu., Nov. 29, 2012 5:00PM
createFromFormat method: Thu., Nov. 29, 2012 5:00PM
-===DONE===
var_dump( $date->format( "H:i:s") );
?>
-===DONE===
--EXPECT--
*** Testing DateTime::format() : basic functionality ***
string(23) "July 14, 2005, 10:30 pm"
string(28) "Thu Jul 14 22:30:41 BST 2005"
string(19) "22:07:41 m is month"
string(8) "22:30:41"
-===DONE===
var_dump( $date->format( DateTime::W3C) ) ;
?>
-===DONE===
--EXPECT--
*** Testing date_format() : basic functionality - formatting coinstants ***
string(25) "2005-07-14T22:30:41+01:00"
string(25) "2005-07-14T22:30:41+01:00"
string(31) "Thu, 14 Jul 2005 22:30:41 +0100"
string(25) "2005-07-14T22:30:41+01:00"
-===DONE===
echo "Summer offset: " . $summer->getOffset() / 3600 . " hours\n";
?>
-===DONE===
--EXPECT--
*** Testing DateTime::getOffset() : basic functionality ***
Winter offset: 0 hours
Summer offset: 1 hours
-===DONE===
var_dump( $object->getTimeZone()->getName() );
?>
-===DONE===
--EXPECT--
*** Testing DateTime::getTimezone() : basic functionality ***
string(13) "Europe/London"
string(16) "America/New_York"
string(19) "America/Los_Angeles"
-===DONE===
echo "After modification 4: " . $datetime->format("D, d M Y") . "\n";
?>
-===DONE===
--EXPECT--
*** Testing DateTime::modify() : basic functionality ***
After modification 1: Sun, 01 Feb 2009
After modification 2: Tue, 10 Feb 2009 18:28:43
After modification 3: Thu, 12 Feb 2009
After modification 4: Sun, 08 Feb 2009
-===DONE===
var_dump( $date2->format( "F j, Y, g:i a") );
?>
-===DONE===
--EXPECTF--
object(DateTime)#%d (3) {
["date"]=>
string(13) "Europe/London"
}
string(23) "July 14, 2005, 10:30 pm"
-===DONE===
echo $datetime->format(DATE_RFC2822) . "\n";
?>
-===DONE===
--EXPECT--
*** Testing DateTime::setDate() : basic functionality ***
Fri, 30 Jan 2009 19:34:10 +0000
Fri, 01 Feb 2008 19:34:10 +0000
-===DONE===
echo "..same day last year was \"" . $datetime->format("D M j") . "\"\n";
?>
-===DONE===
--EXPECT--
*** Testing DateTime::setISODate() : basic functionality ***
Week 40 of 2009 is in "September"
Week 30 day 3 of 2009 is "Wed Jul 22"
..same day last year was "Wed Jul 23"
-===DONE===
echo "After modification5 " . $datetime ->format(DATE_RFC2822) . "\n";
?>
-===DONE===
--EXPECT--
*** Testing DateTime::setTime() : basic functionality ***
Initial date: Sat, 31 Jan 2009 15:14:10 +0000
After modification3 Sun, 01 Feb 2009 00:10:00 +0000
After modification4 Mon, 02 Feb 2009 23:35:47 +0000
After modification5 Wed, 04 Feb 2009 06:25:00 +0000
-===DONE===
echo "New timezone: " . date_timezone_get($datetime)->getName() . "\n";
?>
-===DONE===
--EXPECT--
*** Testing DateTime::setTimezone() : basic functionality ***
Default timezone: Europe/London
New timezone: America/Los_Angeles
-===DONE===
var_dump($method->getParameters()[0]->isOptional());
?>
-===DONE===
--EXPECTF--
*** Verify DateTime class ***
Verify DateTime class registered OK
}
}
bool(false)
-===DONE===
echo $dt->format('Y-m-d H:i:s')."\r\n";
}
?>
-==DONE==
--EXPECTF--
Original:
2010-01-01 00:00:00
2010-01-01 00:00:00
2010-01-02 00:00:00
2010-01-03 00:00:00
-==DONE==
var_dump($di0, $di1);
?>
-==DONE==
--EXPECT--
object(DateInterval)#1 (16) {
["y"]=>
["have_special_relative"]=>
int(0)
}
-==DONE==
var_dump($di);
?>
-==DONE==
--EXPECTF--
object(DateInterval)#%d (16) {
["y"]=>
["f"]=>
float(-1)
}
-==DONE==
$df->days);
?>
-==DONE==
--EXPECTF--
object(DateInterval)#%d (16) {
["y"]=>
float(0)
int(0)
int(2)
-==DONE==
var_dump($di);
?>
-==DONE==
--EXPECTF--
object(DateInterval)#%d (16) {
["y"]=>
["f"]=>
float(-1)
}
-==DONE==
var_dump($di);
?>
-==DONE==
--EXPECTF--
object(DateInterval)#%d (16) {
["y"]=>
["have_special_relative"]=>
int(0)
}
-==DONE==
echo strlen(strftime('%A')), "\n";
?>
-===DONE===
--EXPECT--
90 85 97 6a 93 fa
6
-===DONE===
var_dump( checkdate(7, 2, 0) ); // <min year
?>
-===DONE===
--EXPECT--
*** Testing checkdate() : basic functionality ***
-- The following are all valid dates --
bool(false)
bool(false)
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing date_add() : basic functionality ***
string(19) "2008-01-01 12:25:00"
string(19) "2011-07-06 00:55:05"
string(19) "2011-07-08 00:56:05"
string(19) "2012-09-09 00:41:35"
-===DONE===
var_dump( date("H:i:s", $timestamp) );
?>
-===DONE===
--EXPECT--
*** Testing date() : basic functionality ***
string(27) "February 27, 2009, 10:44 am"
string(28) "Fri Feb 27 10:44:30 GMT 2009"
string(19) "10:02:30 m is month"
string(8) "10:44:30"
-===DONE===
var_dump( date_create("2005-07-14 22:30:41 GMT") );
?>
-===DONE===
--EXPECTF--
*** Testing date_create() : basic functionality ***
object(DateTime)#%d (3) {
["timezone"]=>
string(3) "GMT"
}
-===DONE===
echo date_format($datetime, DATE_RFC2822) . "\n";
?>
-===DONE===
--EXPECT--
*** Testing date_date_set() : basic functionality ***
Fri, 30 Jan 2009 19:34:10 +0000
Fri, 01 Feb 2008 19:34:10 +0000
-===DONE===
var_dump( date_default_timezone_set("foo") );
?>
-===Done===
--EXPECTF--
*** Testing date_default_timezone_set() : error variations ***
Notice: date_default_timezone_set(): Timezone ID 'foo' is invalid in %s on line %d
bool(false)
-===Done===
var_dump( date_format($date, "H:i:s") );
?>
-===DONE===
--EXPECT--
*** Testing date_format() : basic functionality ***
string(23) "July 14, 2005, 10:30 pm"
string(28) "Thu Jul 14 22:30:41 BST 2005"
string(19) "22:07:41 m is month"
string(8) "22:30:41"
-===DONE===
echo "..same day last year was \"" . date_format($datetime, "D M j") . "\"\n";
?>
-===DONE===
--EXPECT--
*** Testing date_isodate_set() : basic functionality ***
Week 40 of 2009 is in "September"
Week 30 day 3 of 2009 is "Wed Jul 22"
..same day last year was "Wed Jul 23"
-===DONE===
echo "After modification 4: " . date_format($datetime, "D, d M Y") . "\n";
?>
-===DONE===
--EXPECT--
*** Testing date_modify() : basic functionality ***
After modification 1: Sun, 01 Feb 2009
After modification 2: Tue, 10 Feb 2009 18:28:43
After modification 3: Thu, 12 Feb 2009
After modification 4: Sun, 08 Feb 2009
-===DONE===
echo "Summer offset: " . date_offset_get($summer) / 3600 . " hours\n";
?>
-===DONE===
--EXPECT--
*** Testing date_offset_get() : basic functionality ***
Winter offset: 0 hours
Summer offset: 1 hours
-===DONE===
var_dump( date_parse("2009-02-27") );
?>
-===DONE===
--EXPECT--
*** Testing date_parse() : basic functionality ***
array(12) {
["is_localtime"]=>
bool(false)
}
-===DONE===
var_dump( date_parse($invalid_date) );
?>
-===DONE===
--EXPECTF--
*** Testing date_parse() : error conditions ***
["zone_type"]=>
int(0)
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing date_sub() : basic functionality ***
string(19) "2008-01-01 12:25:00"
string(19) "2004-06-26 23:54:55"
string(19) "2004-06-24 23:53:55"
string(19) "2003-04-24 00:08:25"
-===DONE===
echo date("D M d Y") . ', sunset time : ' . date_sunset(time(), SUNFUNCS_RET_STRING, 38.4, -9, 90, 1) . "\n";
?>
-===Done===
--EXPECTF--
Basic test for date_sunrise() and date_sunset()
%s %s %d %d, sunrise time : %d:%d
%s %s %d %d, sunset time : %d:%d
-===Done===
}
?>
-===DONE===
--EXPECT--
*** Testing date_sunrise() : usage variation ***
string(5) "06:42"
string(5) "06:22"
string(5) "06:03"
string(5) "06:02"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing date_sunrise() : usage variation ***
bool(false)
bool(false)
bool(false)
-===DONE===
var_dump( date_sunset($time, SUNFUNCS_RET_STRING, $value["Latitude"], $value["Longitude"], 90, $value["GMT"]) );
}
?>
-===DONE===
--EXPECT--
*** Testing date_sunset() : usage variation ***
--Pacific/Wallis--
string(5) "17:36"
string(5) "17:36"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing date_sunset() : usage variation ***
bool(false)
bool(false)
bool(false)
-===DONE===
echo "After modification5 " . date_format($datetime, DATE_RFC2822) . "\n";
?>
-===DONE===
--EXPECT--
*** Testing date_time_set() : basic functionality ***
Initial date: Sat, 31 Jan 2009 15:14:10 +0000
After modification3 Sun, 01 Feb 2009 00:10:00 +0000
After modification4 Mon, 02 Feb 2009 23:35:47 +0000
After modification5 Wed, 04 Feb 2009 06:25:00 +0000
-===DONE===
var_dump( timezone_name_get($tz) );
?>
-===DONE===
--EXPECT--
*** Testing date_timezone_get() : basic functionality ***
string(13) "Europe/London"
string(16) "America/New_York"
string(19) "America/Los_Angeles"
-===DONE===
echo "New timezone: " . timezone_name_get($tz) . "\n";
?>
-===DONE===
--EXPECT--
*** Testing date_timezone_set() : basic functionality ***
Default timezone: Europe/London
New timezone: America/Los_Angeles
-===DONE===
var_dump( getdate() );
?>
-===DONE===
--EXPECTF--
*** Testing getdate() : basic functionality ***
array(11) {
[0]=>
int(%d)
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing getdate() : usage variation ***
[0]=>
int(-8)
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing getdate() : usage variation ***
[0]=>
int(-51966)
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing getdate() : usage variation ***
[0]=>
int(94694400)
}
-===DONE===
var_dump( getdate(0) );
};
?>
-===DONE===
--EXPECT--
*** Testing getdate() : usage variation ***
[0]=>
int(0)
}
-===DONE===
var_dump( getdate($value) );
};
?>
-===DONE===
--EXPECT--
*** Testing getdate() : usage variation ***
[0]=>
int(-10)
}
-===DONE===
var_dump( gettimeofday($get_as_float) );
?>
-===DONE===
--EXPECTF--
*** Testing gettimeofday() : basic functionality ***
float(%f)
["dsttime"]=>
int(0)
}
-===DONE===
var_dump( gmdate($format) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : basic functionality ***
string(24) "2008-08-08T08:08:08+0000"
string(%d) "%s"
-===DONE===
var_dump( gmdate('T', $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
-- Testing gmdate() function with timezone offset format --
string(3) "GMT"
string(3) "GMT"
-===DONE===
var_dump( gmdate('U', $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
-- Testing gmdate() function with seconds since Unix Epoch format --
string(%d) "%d"
string(10) "1218182888"
-===DONE===
var_dump( gmdate(DATE_ISO8601, $timestamp) );
?>
-===DONE===
--EXPECTREGEX--
\*\*\* Testing gmdate\(\) : usage variation \*\*\*
-- Testing gmdate\(\) function with greater than the range of timestamp --
string\(24\) "(1970-01-01T00:00:00\+0000|2038-01-19T03:14:10\+0000)"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
--DATE_W3C Constant--
string(25) "2008-08-08T08:08:08+00:00"
string(%d) "%s"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
--Day of the year--
string(%d) "%d"
string(3) "220"
-===DONE===
var_dump( gmdate('S', $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
-- Testing gmdate() function with English ordinal suffix --
string(%d) "%s"
string(2) "th"
-===DONE===
var_dump( gmdate('W', $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
-- Testing gmdate() function with ISO-8601 week number of year format --
string(%d) "%d"
string(2) "32"
-===DONE===
var_dump( gmdate('t', $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
-- Testing gmdate() function with number of days in a month format --
string(%d) "%d"
string(2) "31"
-===DONE===
var_dump( gmdate('y', $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
-- Testing gmdate() function with 2 digit representation year format --
string(2) "%d"
string(2) "08"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing gmdate() : usage variation ***
--Milliseconds--
string(%d) "%d"
string(6) "000000"
-===DONE===
var_dump( gmmktime($hour, $min, $sec, $mon, $day, $year) );
?>
-===DONE===
--EXPECTF--
*** Testing gmmktime() : basic functionality ***
int(1218182888)
-===DONE===
var_dump( gmmktime($hour, $min, $sec, $mon, $day) );
?>
-===DONE===
--EXPECTF--
*** Testing gmmktime() : usage variation ***
-- Testing gmmktime() function with five optional argument --
int(%d)
-===DONE===
echo "\n-- Testing gmmktime() function with supplying hexa decimal values to arguments --\n";
var_dump( gmmktime($hour, $min, $sec, $mon, $day, $year) );
?>
-===DONE===
--EXPECT--
*** Testing gmmktime() : usage variation ***
-- Testing gmmktime() function with supplying hexa decimal values to arguments --
int(1218182888)
-===DONE===
var_dump( gmmktime($hour, $min, $sec, $mon, $value, $value) );
}
?>
-===DONE===
--EXPECTREGEX--
\*\*\* Testing gmmktime\(\) : usage variation \*\*\*
int\(1218182870\)
int\(1170922088\)
(bool|int)\((false|-62465356312)\)
-===DONE===
var_dump( gmstrftime($format) );
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : basic functionality ***
string(20) "Aug 08 2008 08:08:08"
string(%d) "%s %d %d %d:%d:%d"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Weekday as decimal--
string(%d) "%d"
string(1) "5"
-===DONE===
var_dump( gmstrftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
-- Testing gmstrftime() function with Abbreviated month name format %h --
string(%d) "%s"
string(3) "Aug"
-===DONE===
var_dump( gmstrftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
-- Testing gmstrftime() function with Abbreviated month name format %h --
string(%d) "%s"
string(3) "Aug"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Year without century--
string(2) "%d"
string(2) "08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Year without century--
string(%d) "%d"
string(2) "08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Current time %H:%M:%S format--
string(%d) "%d:%d:%d"
string(8) "08:08:08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Current time %H:%M:%S format--
string(%d) "%d:%d:%d"
string(8) "14:08:08"
-===DONE===
var_dump( gmstrftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
-- Testing gmstrftime() function with Day of the month as decimal single digit format --
string(2) "%A%d"
string(2) " 8"
-===DONE===
var_dump( gmstrftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
-- Testing gmstrftime() function with Day of the month as decimal single digit format --
string(%d) "%s"
string(2) " 8"
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing gmstrftime() : usage variation ***
--Tab character--
string(1) " "
string(1) " "
-===DONE===
};
?>
-===DONE===
--EXPECTREGEX--
\*\*\* Testing gmstrftime\(\) : usage variation \*\*\*
--Tab character--
string\(1\) "\s"
string\(1\) "\s"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Preferred time representation--
string(%d) "%d:%d:%d"
string(8) "08:08:08"
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing gmstrftime() : usage variation ***
--Preferred time representation--
string(2) "%X"
string(8) "08:08:08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Week number of the year in decimal number--
string(%d) "%d"
string(2) "31"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Month as decimal--
string(%d) "%d"
string(2) "08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Time zone offset--
string(%s) "%s"
string(%s) "%s"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Second as decimal number--
string(%d) "%d"
string(2) "08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Day of the week as a decimal number--
string(%d) "%d"
string(1) "5"
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing gmstrftime() : usage variation ***
--A literal % character--
string(1) "%"
string(1) "%"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing gmstrftime() : usage variation ***
--Weekday as decimal--
string(1) "%d"
string(1) "5"
-===DONE===
date_default_timezone_set("Asia/Calcutta");
var_dump( idate($format) );
?>
-===DONE===
--EXPECTF--
*** Testing idate() : basic functionality ***
int(%d)
-===DONE===
var_dump( idate($value) );
};
?>
-===DONE===
--EXPECTF--
*** Testing idate() : usage variation ***
--Day of the year--
int(%d)
-===DONE===
var_dump( idate($value) );
};
?>
-===DONE===
--EXPECTF--
*** Testing idate() : usage variation ***
--Time zone offset--
int(%d)
-===DONE===
$timestamp = mktime(8, 8, 8, 8, 8, 2001);
var_dump( idate($format, $timestamp) );
?>
-===DONE===
--EXPECT--
*** Testing idate() : usage variation ***
-- Testing idate() function for 2 digit year having zero as starting number --
int(1)
-===DONE===
var_dump( localtime() );
?>
-===DONE===
--EXPECTF--
*** Testing localtime() : basic functionality ***
array(9) {
[8]=>
int(%d)
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing localtime() : usage variation ***
["tm_isdst"]=>
int(0)
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing localtime() : usage variation ***
["tm_isdst"]=>
int(0)
}
-===DONE===
var_dump(microtime(false));
?>
-===DONE===
--EXPECTF--
string(%d) "%s %s"
float(%s)
string(%d) "%s %s"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
-- Bad Arg types --
--> bad arg: int(1)
float(%s)
-===DONE===
echo "\n";
}
?>
-===Done===
--EXPECT--
America/Toronto
Y: 0 - January 2000-01-01T01:01:01-0500
Y: 2000 - January 2000-01-01T01:01:01+0100
Y: 2001 - January 2001-01-01T01:01:01+0100
-===Done===
var_dump( mktime($hour, $minute, $sec, $month, $day, $year) );
?>
-===DONE===
--EXPECTF--
*** Testing DateTime::modify() : basic functionality ***
int(%i)
int(%i)
int(%i)
int(%i)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing mktime() : error conditions ***
-- Testing mktime() function with more than expected no. of arguments --
mktime() expects at most 6 parameters, 7 given
-===DONE===
var_dump( strftime($format) );
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : basic functionality ***
string(20) "Aug 08 2008 08:08:08"
string(%d) "%s %d %d %d:%d:%d"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Weekday as decimal--
string(%d) "%d"
string(1) "5"
-===DONE===
var_dump( strftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
-- Testing strftime() function with Abbreviated month name format %h --
string(%d) "%s"
string(3) "Aug"
-===DONE===
var_dump( strftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
-- Testing strftime() function with Abbreviated month name format %h --
string(%d) "%s"
string(3) "Aug"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Year without century--
string(2) "%d"
string(2) "08"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Year without century--
string(%d) "%d"
string(2) "08"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Current time %H:%M:%S format--
string(%d) "%d:%d:%d"
string(8) "08:08:08"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Current time %H:%M:%S format--
string(%d) "%d:%d:%d"
string(8) "08:08:08"
-===DONE===
var_dump( strftime($format) );
var_dump( strftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
-- Testing strftime() function with Day of the month as decimal single digit format --
string(%d) "%A%d"
string(2) " 8"
-===DONE===
var_dump( strftime($format) );
var_dump( strftime($format, $timestamp) );
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
-- Testing strftime() function with Day of the month as decimal single digit format --
string(%d) "%s"
string(2) " 8"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing strftime() : usage variation ***
--Tab character--
string(1) " "
string(1) " "
-===DONE===
}
?>
-===DONE===
--EXPECTREGEX--
\*\*\* Testing strftime\(\) : usage variation \*\*\*
--Tab character--
string\(1\) "\s"
string\(1\) "\s"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Preferred time representation--
string(%d) "%d:%d:%d"
string(8) "08:08:08"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing strftime() : usage variation ***
--Preferred time representation--
string(2) "%X"
string(8) "08:08:08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Week number of the year in decimal number--
string(%d) "%d"
string(2) "31"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Month as decimal--
string(%d) "%d"
string(2) "08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Time zone offset--
string(%d) "%s"
string(%d) "%s"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Second as decimal number--
string(%d) "%d"
string(2) "08"
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Day of the week as a decimal number--
string(%d) "%d"
string(1) "5"
-===DONE===
var_dump( strftime($format, $timestamp) );
?>
-===DONE===
--EXPECT--
*** Testing strftime() : usage variation ***
-- Testing strftime() function with a literal % character to format --
string(1) "%"
string(1) "%"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strftime() : usage variation ***
--Weekday as decimal--
string(1) "%d"
string(1) "5"
-===DONE===
var_dump(time());
?>
-===DONE===
--EXPECTF--
int(%d)
-===DONE===
var_dump( $abbr["acst"] );
?>
-===DONE===
--EXPECTF--
*** Testing timezone_abbreviations_list() : basic functionality ***
string(5) "array"
string(20) "Australia/Yancowinna"
}
}
-===DONE===
var_dump(in_array("UTC", $zones));
?>
-===DONE===
--EXPECT--
*** Testing timezone_identifiers_list() : basic functionality ***
Check return tpe is ARRAY
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump( timezone_name_from_abbr("", 5400) ); // offset = 1.5 hrs
var_dump( timezone_name_from_abbr("", 62400) ); // offset = 24 hrs
?>
-===DONE===
--EXPECT--
*** Testing timezone_name_from_abbr() : basic functionality ***
-- Tests with special cases first - no lookup needed --
-- Tests with invalid offsets --
bool(false)
bool(false)
-===DONE===
var_dump(timezone_offset_get($tz, $date));
?>
-===DONE===
--EXPECTF--
*** Testing timezone_offset_get() : basic functionality ***
%rint\(0\)|int\(3600\)%r
%rint\(-18000\)|int\(-14400\)%r
%rint\(-28800\)|int\(-25200\)%r
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECT--
*** Testing timezone_offset_get() : error conditions ***
string(77) "timezone_offset_get() expects parameter 2 to be DateTimeInterface, null given"
-===DONE===
var_dump( timezone_open("America/Los_Angeles") );
?>
-===DONE===
--EXPECTF--
*** Testing timezone_open() : basic functionality ***
object(DateTimeZone)#%d (2) {
["timezone"]=>
string(19) "America/Los_Angeles"
}
-===DONE===
var_dump( $tran[6] );
?>
-===DONE===
--EXPECT--
*** Testing timezone_transitions_get() : basic functionality ***
["abbr"]=>
string(3) "BST"
}
-===DONE===
dba_close($db);
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
string(3) "XYZ"
string(1) "X"
string(1) "Y"
-===DONE===
echo "Error creating database\n";
}
?>
-===DONE===
--EXPECT--
string(32) "1f34b74bde3744265acfc21e0f30af95"
-===DONE===
dba_close($db);
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
?>
--EXPECT--
bool(false)
-===DONE===
var_dump(dba_delete("a", $dba));
?>
-===DONE===
--CLEAN--
<?php
include "clean.inc";
delete:bool(true)
exists:bool(false)
delete:bool(false)
-===DONE===
dba_close($db);
unlink($filename);
?>
-==DONE==
--EXPECT--
string(2) "23"
string(2) "42"
string(2) "23"
string(2) "42"
string(4) "1337"
-==DONE==
--CLEAN--
<?php
$filename = __DIR__ . DIRECTORY_SEPARATOR . 'bug70825.ini';
dba_close($db);
?>
-==DONE==
--EXPECT--
string(6) "value2"
-==DONE==
--CLEAN--
<?php
$filename = __DIR__ . DIRECTORY_SEPARATOR . 'bug71514.ini';
dba_close($db);
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__ .'/clean.inc');
--EXPECT--
bool(true)
string(3) "baz"
-===DONE===
echo dba_fetch("key2", $db_file1), "\n";
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
Test 6 - query after closing 2nd resource
This is a test insert 1
This is a test insert 2
-===DONE===
$db_file1 = dba_popen($db_filename, 'n-t', 'flatfile');
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
database handler: flatfile
Warning: dba_popen(%stest0.dbm,n-t): You cannot combine modifiers - (no lock) and t (test lock) in %sdba016.php on line %d
-===DONE===
require_once(__DIR__ .'/test.inc');
require_once(__DIR__ .'/dba_handler.inc');
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
["key5"]=>
string(23) "The last content string"
}
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
Warning: dba_open(%stest0.dbm,w): Driver initialization failed for handler: cdb: Update operations are not supported in %sdba_cdb_001.php on line %d
Failed to open DB
-===DONE===
require_once __DIR__ .'/test.inc';
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--EXPECT--
database handler: db1
3NYNYY
["key5"]=>
string(23) "The last content string"
}
-===DONE===
require_once __DIR__ .'/test.inc';
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--EXPECT--
database handler: db2
3NYNYY
["key5"]=>
string(23) "The last content string"
}
-===DONE===
require_once __DIR__ .'/test.inc';
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--EXPECT--
database handler: db3
3NYNYY
["key5"]=>
string(23) "The last content string"
}
-===DONE===
require_once(__DIR__ .'/test.inc');
require_once(__DIR__ .'/dba_handler.inc');
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
["key5"]=>
string(23) "The last content string"
}
-===DONE===
echo dba_fetch("key2", $db_file1), "\n";
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
Test 6 - query after closing 2nd resource
This is a test insert 1
This is a test insert 2
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
database handler: db4
YY
bool(true)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
database handler: db4
YY
bool(true)
-===DONE===
require_once __DIR__ .'/test.inc';
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
["key5"]=>
string(23) "The last content string"
}
-===DONE===
require_once(__DIR__ .'/test.inc');
require_once(__DIR__ .'/dba_handler.inc');
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
["key5"]=>
string(23) "The last content string"
}
-===DONE===
// Read during write is system dependent. Important is that there is no deadlock
?>
-===DONE===
--EXPECTF--
database handler: gdbm
3NYNYY
["key5"]=>
string(23) "The last content string"
}
-===DONE===
require_once __DIR__ .'/test.inc';
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
["key5"]=>
string(23) "The last content string"
}
-===DONE===
$lock_flag = ''; // lock in library
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--CLEAN--
<?php
require_once __DIR__ .'/clean.inc';
["key5"]=>
string(23) "The last content string"
}
-===DONE===
require_once __DIR__ .'/test.inc';
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--EXPECT--
database handler: ndbm
3NYNYY
["key5"]=>
string(23) "The last content string"
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
database handler: flatfile
2YY
bool(true)
-===DONE===
$lock_flag = ''; // lock in library
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
["key5"]=>
string(23) "The last content string"
}
-===DONE===
var_dump(dba_key_split("[key1]name1"));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
array(2) {
[0]=>
[1]=>
string(5) "name1"
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--CLEAN--
<?php
require(__DIR__ .'/clean.inc');
database handler: flatfile
2YY
bool(true)
-===DONE===
@unlink($db_filename.'.lck');
require_once __DIR__ .'/dba_handler.inc';
?>
-===DONE===
--CLEAN--
<?php
$db_filename = $db_file = __DIR__ .'/test0.tch';
["key5"]=>
string(23) "The last content string"
}
-===DONE===
$character_data = new DOMCharacterData();
print $character_data->length;
?>
-===DONE===
--EXPECTF--
Warning: main(): Invalid State Error in %s
-===DONE===
echo "EXPECTING NOT SAME NODE, PASSED\n" ;
?>
-===DONE===
--EXPECT--
EXPECTING SAME NODE, PASSED
EXPECTING NOT SAME NODE, PASSED
-===DONE===
echo "\n" . $document->saveXML();
?>
-===DONE===
--EXPECT--
Text Length (one append): 4
Text Length (two appends): 8
<?xml version="1.0"?>
<root><text>data><&"</text></root>
-===DONE===
var_dump($doc->firstChild->nodeValue, empty($doc->firstChild->nodeValue), isset($doc->firstChild->nodeValue));
var_dump(empty($doc->nodeType), empty($doc->firstChild->nodeType))
?>
-===DONE===
--EXPECT--
DOMNodeList
int(0)
bool(true)
bool(false)
bool(false)
-===DONE===
echo get_class($n), "\n";
print $doc->saveXML();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
DOMDocumentType
<?xml version="1.0" encoding="utf-8"?>
<set><foo>footext</foo><bar>bartext</bar></set>
-===DONE===
$frag2->appendChild($dom->createElement('div'));
var_dump($dom->saveHTML($frag2));
?>
-===DONE===
--EXPECT--
string(0) ""
string(46) "<div><span></span></div><div></div><div></div>"
-===DONE===
$domDocument->load(__DIR__ . DIRECTORY_SEPARATOR . "dom.xml");
var_dump($domDocument->doctype->internalSubset);
?>
-===DONE===
--EXPECT--
string(19) "<!ELEMENT a EMPTY>
"
<!ELEMENT root (foo)+>
<!ATTLIST th title CDATA #IMPLIED>
"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
int(3)
object(DOMText)#%d (19) {
string(1) "
"
}
-===DONE===
printf("Parameter #%d %s OPTIONAL\n", $param->getPosition(), $param->isOptional() ? "IS" : "IS NOT");
}
?>
-===DONE===
--EXPECT--
1
0
Parameter #0 IS OPTIONAL
-===DONE===
$dom->loadHTML($htm);
var_dump($dom->doctype->name);
?>
-===DONE===
--EXPECTF--
Warning: DOMDocument::loadHTML(): htmlParseDocTypeDecl : no DOCTYPE name ! in Entity, line: 1 in %s on line %d
string(0) ""
-===DONE===
$objRef = $objDoc->createEntityReference('Test');
echo $objRef->nodeName . "\n";
?>
-===DONE===
--EXPECT--
Test
-===DONE===
$infile = __DIR__.'/bug34704私はガラスを食べられます.jpg';
var_dump(exif_read_data($infile));
?>
-===DONE===
--EXPECTF--
array(7) {
["FileName"]=>
int(0)
}
}
-===DONE===
$infile = __DIR__.'/bug34704.jpg';
var_dump(exif_read_data($infile));
?>
-===DONE===
--EXPECTF--
array(7) {
["FileName"]=>
int(0)
}
}
-===DONE===
$infile = __DIR__.'/bug50660-2.jpg';
var_dump(exif_read_data($infile) !== false);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
$infile = __DIR__.'/bug60150.jpg';
var_dump(exif_read_data($infile));
?>
-===DONE===
--EXPECTF--
Warning: exif_read_data(bug60150.jpg): Process tag(x9003=DateTimeOriginal): Illegal pointer offset(%s) in %s on line %d
Warning: exif_read_data(bug60150.jpg): Invalid JPEG file in %s on line %d
bool(false)
-===DONE===
<?php
var_dump(exif_read_data(__DIR__ . DIRECTORY_SEPARATOR . 'bug68547.jpg'));
?>
-===DONE===
--EXPECTF--
array(12) {
["FileName"]=>
["Title"]=>
string(8) "Title..."
}
-===DONE===
$infile = __DIR__.'/bug72819.jpg';
var_dump(strlen(exif_thumbnail($infile)));
?>
-===DONE===
--EXPECT--
int(5448)
-===DONE===
$infile = __DIR__.'/bug73115.jpg';
var_dump(count(exif_read_data($infile)));
?>
-===DONE===
--EXPECT--
int(80)
-===DONE===
$infile = __DIR__.'/bug74428.jpg';
var_dump(exif_read_data($infile));
?>
-===DONE===
--EXPECTF--
array(11) {
["FileName"]=>
["ExifImageLength"]=>
int(28)
}
-===DONE===
<?php
exif_read_data('.');
?>
-===DONE===
--EXPECTF--
Warning: exif_read_data(): %s in %s on line %d
-===DONE===
<?php
exif_read_data(__DIR__ . '/bug76423.jpg', 0, true, true);
?>
-===DONE===
--EXPECTF--
Warning: exif_read_data(%s.jpg): Thumbnail goes IFD boundary or end of file reached in %s on line %d
Warning: exif_read_data(%s.jpg): File structure corrupted in %s on line %d
Warning: exif_read_data(%s.jpg): Invalid JPEG file in %s on line %d
-===DONE===
echo $tags['GPSLatitude'][2], PHP_EOL;
echo $tags['GPSLongitude'][2], PHP_EOL;
?>
-===DONE===
--EXPECT--
156691934/70000000
2672193571/70000000
-===DONE===
$exif_data = exif_read_data($infile);
echo "*** no core dump ***\n";
?>
-===DONE===
--EXPECT--
*** no core dump ***
-===DONE===
var_dump(exif_imagetype(__DIR__.'/test2私はガラスを食べられます.jpg'));
?>
-===Done===
--EXPECT--
*** Testing exif_imagetype() : basic functionality ***
int(2)
-===Done===
var_dump(exif_imagetype(__DIR__.'/test2.jpg'));
?>
-===Done===
--EXPECT--
*** Testing exif_imagetype() : basic functionality ***
int(2)
-===Done===
?>
-===Done===
--EXPECTF--
*** Testing exif_imagetype() : error conditions ***
Warning: exif_imagetype(%s/foo.jpg): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===Done===
$infile = __DIR__.'/bug73115.JPG';
exif_read_data($infile);
?>
-===DONE===
--EXPECTF--
Warning: exif_read_data(): Unable to open file in %sexif_read_data_0.php on line %d
-===DONE===
var_dump(exif_tagname(0x110));
?>
-===Done===
--EXPECT--
*** Testing exif_tagname() : basic functionality ***
string(16) "ImageDescription"
string(4) "Make"
string(5) "Model"
-===Done===
}
?>
-===DONE===
--EXPECT--
string(9) "directory"
string(9) "directory"
string(28) "text/x-php; charset=us-ascii"
string(28) "text/x-php; charset=us-ascii"
-===DONE===
unlink($magic_file_copy2);
rmdir($dir);
?>
-===DONE===
--EXPECTF--
bool(false)%A
resource(%d) of type (file_info)
Warning: finfo_open(): Failed to load magic database at '%sbug61964-mb'. in %sbug61964-mb.php on line %d
DONE: testing dir with files
-===DONE===
unlink($magic_file_copy2);
rmdir($dir);
?>
-===DONE===
--EXPECTF--
bool(false)%A
resource(%d) of type (file_info)
Warning: finfo_open(): Failed to load magic database at '%sbug61964'. in %sbug61964.php on line %d
DONE: testing dir with files
-===DONE===
var_dump($f->file(__DIR__ . "/bug67516.gif", FILEINFO_MIME_TYPE));
var_dump($f->file(__DIR__ . "/bug67516.gif", FILEINFO_MIME));
?>
-===DONE===
--EXPECT--
string(9) "image/gif"
string(25) "image/gif; charset=binary"
-===DONE===
var_dump($f->file($test_file));
?>
-===DONE===
--EXPECTF--
string(%d) "JPEG image data, JFIF standard 1.01, resolution (DPI), density 180x52, segment length 16, comment: "%S""
-===DONE===
var_dump($finfo->buffer("<?php\tclass A{}"));
var_dump($finfo->buffer("<?php\n\rclass A{}"));
?>
-===DONE===
--EXPECT--
string(10) "text/x-php"
string(10) "text/x-php"
string(10) "text/x-php"
string(10) "text/x-php"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing finfo_buffer() : basic functionality ***
string(36) "ASCII text, with no line terminators"
string(28) "text/plain; charset=us-ascii"
string(28) "text/plain; charset=us-ascii"
string(25) "text/plain; charset=utf-8"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing finfo_buffer() : basic functionality ***
string(36) "ASCII text, with no line terminators"
string(28) "text/plain; charset=us-ascii"
string(28) "text/plain; charset=us-ascii"
string(25) "text/plain; charset=utf-8"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing finfo_buffer() : variation functionality with oo interface ***
string(36) "ASCII text, with no line terminators"
string(28) "text/plain; charset=us-ascii"
string(28) "text/plain; charset=us-ascii"
string(25) "text/plain; charset=utf-8"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing finfo_buffer() : variation functionality with oo interface ***
string(36) "ASCII text, with no line terminators"
string(28) "text/plain; charset=us-ascii"
string(28) "text/plain; charset=us-ascii"
string(25) "text/plain; charset=utf-8"
-===DONE===
unset( $finfo );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_close() : basic functionality ***
resource(%d) of type (file_info)
bool(true)
object(finfo)#%d (%d) {
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing finfo_close() : error conditions ***
-- Testing finfo_close() function with wrong resource type --
finfo_close(): supplied resource is not a valid file_info resource
-===DONE===
var_dump($f->file(__DIR__ . "/resources/test.jpg", FILEINFO_EXTENSION));
?>
-===DONE===
--EXPECT--
string(17) "jpeg/jpg/jpe/jfif"
-===DONE===
var_dump( finfo_file( $finfo, $magicFile.chr(0).$magicFile) );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_file() : basic functionality ***
string(28) "text/x-php; charset=us-ascii"
Warning: finfo_file(): Invalid path in %s%efinfo_file_basic.php on line %d
bool(false)
-===DONE===
var_dump( finfo_file( $finfo, $file, FILEINFO_CONTINUE ) );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_file() : regex rules ***
string(28) "text/plain; charset=us-ascii"
string(%d) "awk%sscript, ASCII text%A"
-===DONE===
var_dump( new finfo() );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_open() : basic functionality ***
resource(%d) of type (file_info)
}
object(finfo)#%d (%d) {
}
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing finfo_open() : error functionality ***
resource(6) of type (file_info)
finfo_open() expects parameter 1 to be int, string given
finfo::__construct() expects parameter 1 to be int, string given
-===DONE===
var_dump( finfo_open( FILEINFO_DEVICES | FILEINFO_RAW, $magicFile ) );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_open() : variations in opening ***
resource(%d) of type (file_info)
resource(%d) of type (file_info)
-===DONE===
var_dump(preg_match("/fileinfo support => enabled/", $output));
?>
-===DONE===
--EXPECT--
*** Testing finfo extension : loading info phpinfo() ***
int(1)
-===DONE===
var_dump( $finfo->set_flags( FILEINFO_MIME ) );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_set_flags() : basic functionality ***
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump( $finfo->set_flags( FILEINFO_MIME ) );
?>
-===DONE===
--EXPECTF--
*** Testing finfo_set_flags() : basic functionality ***
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump(filter_var("invalid", FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE));
?>
-==DONE==
--EXPECT--
bool(false)
bool(false)
bool(true)
bool(true)
NULL
-==DONE==
$options = ['flags' => FILTER_FLAG_ALLOW_THOUSAND, 'options' => ['thousand' => '']];
var_dump(filter_var('12345', FILTER_VALIDATE_FLOAT, $options));
?>
-===DONE===
--EXPECTF--
float(1000)
float(1234.567)
Warning: filter_var(): thousand separator must be at least one char in %s on line %d
bool(false)
-===DONE===
])
);
?>
-===DONE===
--EXPECT--
int(2)
int(2)
-===DONE===
require_once __DIR__ . '/func.inc';
test_image_equals_file(__DIR__ . '/bug47946_exp.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
imagedestroy($im);
?>
-===DONE===
--EXPECT--
The images are similar.
-===DONE===
include_once __DIR__ . '/func.inc';
test_image_equals_file(__DIR__ . '/bug52070.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
imagedestroy($img);
print_r($results);
?>
-===DONE===
--EXPECT--
Array
(
)
)
-===DONE===
include_once __DIR__ . '/func.inc';
test_image_equals_file(__DIR__ . '/bug66005.png', $dest);
?>
-==DONE==
--EXPECT--
The images are equal.
-==DONE==
imagedestroy($im);
?>
-===DONE===
--EXPECT--
int(0)
-===DONE===
test_image_equals_file(__DIR__ . DIRECTORY_SEPARATOR . 'bug72482_2.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
include_once __DIR__ . '/func.inc';
test_image_equals_file(__DIR__ . '/bug72913.png', $dst);
?>
-==DONE==
--EXPECT--
The images are equal.
-==DONE==
printf("y chunk count: %d\n", $header['y_count']);
printf("file size: %d\n", strlen($buffer));
?>
-===DONE===
--EXPECT--
chunk size: 64
x chunk count: 1
y chunk count: 1
file size: 5145
-===DONE===
$header = unpack('@10/nchunk_size', $buffer);
printf("chunk size: %d\n", $header['chunk_size']);
?>
-===DONE===
--EXPECT--
chunk size: 256
-===DONE===
$header = unpack('@12/nformat', $buffer);
printf("format: %d\n", $header['format']);
?>
-===DONE===
--EXPECT--
format: 4
-===DONE===
$im = imagecreatefromgd2(__DIR__ . DIRECTORY_SEPARATOR . 'bug73161.gd2');
var_dump($im);
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromgd2(): '%s' is not a valid GD2 file in %s on line %d
bool(false)
-===DONE===
test_image_equals_file(__DIR__ . DIRECTORY_SEPARATOR . 'bug73213.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
test_image_equals_file(__DIR__ . DIRECTORY_SEPARATOR . 'bug73272.png', $dst);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
$dst = imagescale($src, 200, 200, IMG_BILINEAR_FIXED);
printf("color: %x\n", imagecolorat($dst, 99, 99));
?>
-===DONE===
--EXPECT--
color: ffffff
-===DONE===
$dst = imagescale($src, 200, 200, IMG_BILINEAR_FIXED);
printf("color: %x\n", imagecolorat($dst, 99, 99));
?>
-===DONE===
--XFAIL--
Bug #330 has not yet been fixed
--EXPECT--
color: ffffff
-===DONE===
printf("%3d, %3d: %x\n", $x, $y, imagecolorat($dst, $x, $y));
}
?>
-===DONE===
--EXPECT--
truecolor source
0, 0: ffffff
0, 199: ffffff
199, 199: ffffff
199, 0: ffffff
-===DONE===
}
?>
-===DONE===
--EXPECT--
size: 247*247
size: 237*237
size: 229*229
size: 175*175
-===DONE===
var_dump(imagepng($im, $stream));
var_dump($stream);
?>
-===DONE===
--EXPECTF--
bool(true)
resource(%d) of type (stream)
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . DIRECTORY_SEPARATOR . 'bug73549.png');
test_image_equals_file(__DIR__ . '/bug73614.png', $image);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
<?php
var_dump(imagecreatefromgd2(__DIR__ . DIRECTORY_SEPARATOR . 'bug73868.gd2'));
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromgd2(): gd2: EOF while reading
in %s on line %d
Warning: imagecreatefromgd2(): '%s' is not a valid GD2 file in %s on line %d
bool(false)
-===DONE===
var_dump(imagecreatefromgd2(__DIR__ . DIRECTORY_SEPARATOR . 'bug73869a.gd2'));
var_dump(imagecreatefromgd2(__DIR__ . DIRECTORY_SEPARATOR . 'bug73869b.gd2'));
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromgd2(): '%s' is not a valid GD2 file in %s on line %d
bool(false)
Warning: imagecreatefromgd2(): '%s' is not a valid GD2 file in %s on line %d
bool(false)
-===DONE===
var_dump(imagesx($im));
}
?>
-===DONE===
--EXPECT--
bool(false)
-===DONE===
var_dump(imagecreatefromstring($str));
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromstring(): Passed data is not in 'BMP' format in %s on line %d
Warning: imagecreatefromstring(): Couldn't create GD Image Stream out of Data in %s on line %d
bool(false)
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump($rf->getNumberOfParameters());
var_dump($rf->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(3)
int(1)
-===DONE===
<?php
var_dump(imagecreatefromgif(__DIR__ . '/bug75571.gif'));
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromgif(): '%s' is not a valid GIF file in %s on line %d
bool(false)
-===DONE===
@imagecreatefromjpeg($filename);
imagecreatefromjpeg($filename);
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: JPEG datastream contains no image in %s on line %d
Warning: imagecreatefromjpeg(): '%s' is not a valid JPEG file in %s on line %d
-===DONE===
var_dump(imagesx($cropped));
?>
-===DONE===
--EXPECT--
int(4)
int(4)
-===DONE===
imagescale($im, 1, 1, IMG_TRIANGLE);
?>
-===DONE===
--EXPECTF--
Warning: imagescale():%S product of memory allocation multiplication would exceed INT_MAX, failing operation gracefully
in %s on line %d
-===DONE===
$img = imagecreate(2**28, 1);
var_dump(imagescale($img, 1, 1, IMG_TRIANGLE));
?>
-===DONE===
--EXPECTF--
Warning: imagescale():%S product of memory allocation multiplication would exceed INT_MAX, failing operation gracefully
in %s on line %d
bool(false)
-===DONE===
imagecolorallocate($im, 0, 0, 0);
imagewbmp($im, __DIR__ . '/77479.wbmp');
?>
-===DONE===
--EXPECTF--
Warning: imagewbmp():%S product of memory allocation multiplication would exceed INT_MAX, failing operation gracefully
in %s on line %d
Warning: imagewbmp(): Could not create WBMP in %s on line %d
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/77479.wbmp');
$im = imagecreatefromgif(__DIR__ . 'bug77700.gif');
var_dump(imageinterlace($im));
?>
-===DONE===
--EXPECT--
int(1)
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . 'bug77700.gif');
test_image_equals_file(__DIR__ . '/bug77943.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
$im = imagecreatefromxbm($filepath);
var_dump($im);
?>
-===DONE===
--EXPECTF--
Warning: imagecreatefromxbm(): invalid XBM in %s on line %d
Warning: imagecreatefromxbm(): '%s' is not a valid XBM file in %s on line %d
bool(false)
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/bug77973.xbm');
var_dump(gd_info());
?>
-===DONE===
--EXPECTF--
*** Testing gd_info() : variation ***
array(%d) {
["JIS-mapped Japanese Font Support"]=>
bool(%s)
}
-===DONE===
var_dump( imagecolorallocate($im, 0, 0, 255) );
var_dump( imagecolorallocate($im, 255, 255, 255) );
?>
-===DONE===
--EXPECT--
*** Testing imagecolorallocate() : basic functionality ***
int(16711680)
int(65280)
int(255)
int(16777215)
-===DONE===
);
};
?>
-===DONE===
--EXPECT--
*** Testing imagecolorallocate() : usage variations ***
int(16714250)
int(720650)
int(658175)
-===DONE===
);
};
?>
-===DONE===
--EXPECT--
*** Testing imagecolorallocate() : usage variations ***
!! [ValueError] Green component is out of range, must be between 0 and 255 (inclusive)
!! [ValueError] Blue component is out of range, must be between 0 and 255 (inclusive)
!! [ValueError] Blue component is out of range, must be between 0 and 255 (inclusive)
-===DONE===
imagedestroy($im);
?>
-===DONE===
--EXPECT--
*** Testing imagecolorstotal() : basic functionality ***
Total colors in image: 128
-===DONE===
imagedestroy( $img );
?>
-===DONE===
--EXPECT--
*** Testing imagecolorstotal() : basic functionality ***
int(0)
int(3)
int(0)
int(0)
-===DONE===
include_once __DIR__ . '/func.inc';
test_image_equals_file(__DIR__ . '/imagecreatefrombmp_basic.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
include_once __DIR__ . '/func.inc';
test_image_equals_file(__DIR__ . '/imagecreatefromstring_bmp.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
var_dump(imagesy($im));
?>
-===DONE===
--EXPECT--
int(10)
int(10)
-===DONE===
var_dump(imagesy($im));
?>
-===DONE===
--EXPECT--
int(10)
int(10)
-===DONE===
var_dump(imagesy($im));
?>
-===DONE===
--EXPECT--
int(10)
int(10)
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
palette gamma (1, 2): The images are equal.
truecolor gamma (1, 2): The images are equal.
truecolor gamma (1, 1): The images are equal.
palette gamma (2, 1): The images are equal.
truecolor gamma (2, 1): The images are equal.
-===DONE===
test_image_equals_file(__DIR__ . DIRECTORY_SEPARATOR . 'imagegd_truecolor.png', $im);
?>
-===DONE===
--EXPECT--
signature: 65534
truecolor: 1
size: 411
The images are equal.
-===DONE===
test_image_equals_file(__DIR__ . DIRECTORY_SEPARATOR . 'imageopenpolygon.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
test_image_equals_file(__DIR__ . DIRECTORY_SEPARATOR . 'imagepolygon_aa.png', $im);
?>
-===DONE===
--EXPECT--
The images are equal.
-===DONE===
$act = imagecreatefromjpeg($filename);
var_dump(imageresolution($act));
?>
-===DONE===
--EXPECT--
array(2) {
[0]=>
[1]=>
int(299)
}
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . DIRECTORY_SEPARATOR . 'imageresolution_jpeg.jpeg');
$act = imagecreatefrompng($filename);
var_dump(imageresolution($act));
?>
-===DONE===
--EXPECT--
array(2) {
[0]=>
[1]=>
int(299)
}
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . DIRECTORY_SEPARATOR . 'imageresolution_png.png');
test_image_equals_file($filename, $im);
?>
-===DONE===
--EXPECT--
The images differ in 25 pixels.
The images are equal.
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . DIRECTORY_SEPARATOR . 'test_image_equals_file_palette.png');
var_dump(textdomain($overflown));
?>
-==DONE==
--EXPECTF--
Warning: bindtextdomain(): domain passed too long in %s on line %d
bool(false)
Warning: textdomain(): domain passed too long in %s on line %d
bool(false)
-==DONE==
}
?>
-==DONE==
--EXPECT--
LC_ALL=de_DE
hello=hallo
LC_ALL=en_US
hello=hello
-==DONE==
var_dump(textdomain(null));
?>
-===DONE===
--EXPECT--
string(8) "messages"
-===DONE===
var_dump(hash_algos());
?>
-===Done===
--EXPECTF--
*** Testing hash_algos() : basic functionality ***
array(53) {
[%d]=>
string(10) "haval256,5"
}
-===Done===
var_dump(hash('foo', ''));
?>
-===Done===
--EXPECTF--
*** Testing hash() : error conditions ***
Warning: hash(): Unknown hashing algorithm: foo in %s on line %d
bool(false)
-===Done===
var_dump( base64_encode( hash_file( 'md5', $filename, true ) ) );
?>
-===DONE===
--CLEAN--
<?php
string(64) "68b1282b91de2c054c36629cb8dd447f12f096d3e3c587978dc2248444633483"
string(128) "0a8c150176c2ba391d7f1670ef4955cd99d3c3ec8cf06198cec30d436f2ac0c9b64229b5a54bdbd5563160503ce992a74be528761da9d0c48b7c74627302eb25"
string(24) "XG/73UDZVWtzoh5jw+DpBA=="
-===DONE===
unlink($file);
?>
-===Done===
--EXPECT--
*** Testing hash_file() : basic functionality ***
adler32: ff87222e
adler32(raw): ff87222e
md5(raw): 704bf818448f5bbb94061332d2c889aa
sha256(raw): a0f5702fa5d3670b80033d668e8732b70550392abb53841355447f8bb0f72245
-===Done===
var_dump( hash_file( 'md5', 'nonexistent.txt' ) );
?>
-===DONE===
--CLEAN--
<?php
Warning: hash_file(%s): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
fn() => hash_hkdf('sha1', $ikm, 20 * 255 + 1) // Length can't be more than 255 times the hash digest size
)
?>
-===Done===
--EXPECT--
*** Testing hash_hkdf(): error conditions ***
[Error] Input keying material cannot be empty
[Error] Length must be greater than or equal to 0: -1
[Error] Length must be less than or equal to 5100: 5101
-===Done===
''
)), "\n";
?>
-===Done===
--EXPECT--
*** Testing hash_hkdf(): RFC 5869 test vectors ***
Test case 1 (SHA-256): 3cb25f25faacd57a90434f64d0362f2a2d2d0a90cf1a5a4c5db02d56ecc4c5bf34007208d5b887185865
Test case 5 (SHA-1 with longer inputs/outputs): 0bd770a74d1160f7c9f12cd5912a06ebff6adcae899d92191fe4305673ba2ffe8fa3f1a4e5ad79f3f334b3b202b2173c486ea37ce3d397ed034c7f9dfeb15c5e927336d0441f4c4300e2cff0d0900b52d3b4
Test case 6 (SHA-1 with zero-length salt, info): 0ac1af7002b3d761d1e55298da9d0506b9ae52057220a306e07b6b87e8df21d0ea00033de03984d34918
Test case 7 (SHA-1 with zero-length info, salt not provided): 2c91117204d745f3500d636a62f64f0ab3bae548aa53d423b0d1f27ebba6f5e5673a081d70cce7acfc48
-===Done===
echo "sha256(raw): " . bin2hex(hash_hmac('sha256', $content, $key, TRUE)) . "\n";
?>
-===Done===
--EXPECT--
*** Testing hash_hmac() : basic functionality ***
gost: a4a3c80bdf3f8665bf07376a34dc9c1b11af7c813f4928f62e39f0c0dc564dad
whirlpool: 4a0f1582b21b7aff59bfba7f9c29131c69741b2ce80acdc7d314040f3b768cf5a17e30b74cceb86fbc6b34b1692e0addd5bfd7cfc043d40c0621f1b97e26fa49
md5(raw): 2a632783e2812cf23de100d7d6a463ae
sha256(raw): 49bde3496b9510a17d0edd8a4b0ac70148e32a1d51e881ec76faa96534125838
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing hash_hmac() : error conditions ***
-- Testing hash_hmac() function with non-cryptographic hash algorithm --
Non-cryptographic hashing algorithm: crc32
-===Done===
unlink($file);
?>
-===Done===
--EXPECTF--
*** Testing hash_hmac_file() : basic functionality ***
gost: 94c39a40d5db852a8dc3d24e37eebf2d53e3d711457c59cd02b614f792a9d918
whirlpool: 37a0fbb90547690d5e5e11c046f6654ffdb7bab15e16d9d79c7d85765cc4bdcbfd9df8db7a3ce9558f3f244fead00ca29cf05297f75596555195a0683f15d69f
md5(raw): 8bddf39dd1c566c27acc7fa85ec36acf
sha256(raw): 9135286ca4c84dec711e4b831f6cd39e672e5ff93d011321274eb76733cc1e40
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing hash() : error conditions ***
-- Testing hash_hmac_file() function with bad path --
Invalid path
-===Done===
echo "sha256(rounds)(raw): " . bin2hex(hash_pbkdf2('sha256', 'passwordPASSWORDpassword', 'saltSALTsaltSALTsaltSALTsaltSALTsalt', 4096, 40, TRUE))."\n";
?>
-===Done===
--EXPECT--
*** Testing hash_pbkdf2() : basic functionality ***
sha1: 0c60c80f961f0e71f3a9
sha256(raw): 120fb6cffcf8b32c43e7225256c4f837a86548c9
sha256(rounds): 348c89dbcbd32b2f32d814b8116e84cf2b17347e
sha256(rounds)(raw): 348c89dbcbd32b2f32d814b8116e84cf2b17347ebc1800181c4e2a1fb8dd53e1c635518c7dac47e9
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing hash_pbkdf2() : error conditions ***
-- Testing hash_pbkdf2() function with invalid length --
Length must be greater than or equal to 0: -1
-===Done===
);
var_dump(iconv_mime_encode('subject', "d obeybiubrsfqllpdtpge…", $preferences));
?>
-===DONE===
--EXPECT--
string(54) "subject: =?utf-8?Q?d=20obeybiubrsfqllpdtpge=E2=80=A6?="
-===DONE===
HEADERS;
var_dump(iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_STRICT));
?>
-===DONE===
--EXPECT--
array(2) {
["X-Header-One"]=>
["X-Header-Two"]=>
string(17) "XtLePq6GTMn8G68F0"
}
-===DONE===
var_dump(iconv_mime_decode('ö'));
var_dump(iconv_mime_decode('ß'));
?>
-===DONE===
--EXPECTF--
Notice: iconv_mime_decode(): Detected an illegal character in input string in %s on line %d
bool(false)
Notice: iconv_mime_decode(): Detected an illegal character in input string in %s on line %d
bool(false)
-===DONE===
var_dump(iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_CONTINUE_ON_ERROR));
var_dump(iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_STRICT));
?>
-===DONE===
--EXPECT--
array(10) {
["From"]=>
["Content-Language"]=>
string(5) "en-us"
}
-===DONE===
);
var_dump(iconv_mime_encode("Subject", "Test Test Test Test Test Test Test Test", $preferences));
?>
-===DONE===
--EXPECT--
string(74) "Subject: =?UTF-8?Q?Test=20Test=20Test=20Test=20Test=20Test=20Test=20Test?="
-===DONE===
$decoded = iconv_mime_decode($original, ICONV_MIME_DECODE_STRICT, 'utf-8');
var_dump($decoded);
?>
-===DONE===
--EXPECT--
string(183) "『【外資系戦略コンサルが集結】トップコンサルタントと話せるコンサル業界研究セミナー』へのエントリーありがとうございました。"
-===DONE===
$headers = iconv_mime_decode_headers($string, ICONV_MIME_DECODE_CONTINUE_ON_ERROR);
var_dump($headers);
?>
-===DONE===
--EXPECT--
array(1) {
["Feedback-ID"]=>
string(86) "014a93e3-1f5e-4df6-b347-6b59f0f746b8:b5891053-55d1-45bc-a0b5-47a7a9b59687:email:epslh1"
}
-===DONE===
echo "\n-- Multibyte String --\n";
var_dump(iconv_strlen($string_mb, 'UTF-8'));
?>
-===DONE===
--EXPECT--
*** Testing iconv_strlen() : basic functionality***
-- Multibyte String --
int(21)
-===DONE===
var_dump(iconv_strlen($string, $encoding));
?>
-===DONE===
--EXPECTF--
*** Testing iconv_strlen() : error ***
Notice: iconv_strlen(): Wrong charset, conversion from `unknown-encoding' to `UCS-4LE' is not allowed in %s on line %d
bool(false)
-===DONE===
unlink($fn);
?>
-==DONE==
--EXPECTF--
Warning: imap_append(): internal date not correctly formatted in %s on line %d
Exception: imap_append(): supplied resource is not a valid imap resource
-==DONE==
<?php
imap_mail('1', 1, NULL);
?>
-===DONE===
--EXPECTF--
Warning: imap_mail(): No message string in mail command in %s on line %d
%A
-===DONE===
var_dump(imap_8bit("\x00\x01\x02\x03\x04\xfe\xff\x0a\x0d"));
?>
-===Done===
--EXPECT--
*** Testing imap_8bit() : basic functionality ***
string(28) "String with CRLF at end=20
string(33) "String with tabs =09=09 in middle"
string(26) "String with tab at end =09"
string(27) "=00=01=02=03=04=FE=FF=0A=0D"
-===Done===
var_dump( imap_alerts($extra_arg) );
?>
-===DONE===
--EXPECTF--
*** Testing imap_alerts() : error conditions ***
Warning: imap_alerts() expects exactly 0 parameters, 1 given in %s on line %d
NULL
-===DONE===
imap_close($imap_stream);
?>
-===Done===
--CLEAN--
<?php
require_once('clean.inc');
[1]=>
string(%d) "%w%s 2)%s webmaster@something. Another test (%d chars)"
}
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing imap_base64() : basic functionality ***
TEST PASSED
TEST PASSED
TEST PASSED
-===Done===
var_dump(bin2hex($base64));
?>
-===Done===
--EXPECTF--
*** Testing imap_binary() : basic functionality ***
Encode as short string
string(60) "5879737450587464573130374f30422b497a3876506934384c413d3d0d0a"
Encode some hexadecimal data
string(144) "65444177584867774d5678344d444a636544417a584867774e4678344d445663654441325848684751567834526b4a6365455a4458486847524678340d0a526b566365455a470d0a"
-===Done===
imap_close($imap_stream);
?>
-===Done===
--CLEAN--
<?php
require_once('clean.inc');
Msg Count in new mailbox: 1
string(%d) "1: this is a test message, please ignore%a"
string(%d) "1: this is a test message, please ignore%a"
-===Done===
return $result;
}
?>
-===Done===
--CLEAN--
<?php
require_once('clean.inc');
Try to get part 4!
bool(false)
-===Done===
imap_close($imap_stream);
?>
-===Done===
--CLEAN--
<?php
require_once('clean.inc');
int(10)
}
bool(false)
-===Done===
echo "\n-- Call to imap_close() with mandatory arguments --\n";
var_dump( imap_close($stream_id) );
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
-- Call to imap_close() with mandatory arguments --
bool(true)
-===DONE===
$extra_arg = 10;
var_dump( imap_close($stream_id, $options, $extra_arg) );
?>
-===DONE===
--EXPECTF--
*** Testing imap_close() : error conditions ***
Warning: imap_close() expects at most 2 parameters, 3 given in %s on line %d
NULL
-===DONE===
};
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Warning: imap_close(): invalid value for the flags parameter in %s on line %d
bool(false)
-===DONE===
imap_close($imap_stream);
?>
-===Done===
--EXPECTF--
*** Testing imap_createmailbox() : basic functionality ***
Newname will be 'phpnewbox'
UIDnext: %d
UIDvalidity: %d
Mailbox 'phpnewbox' removed to restore initial state
-===Done===
echo "List any errors\n";
var_dump(imap_errors());
?>
-===Done===
--EXPECTF--
*** Testing imap_errors() : basic functionality ***
Issue open with invalid password with normal default number of retries, i.e 3
[0]=>
string(%d) "%a
}
-===Done===
imap_close($stream_id);
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
seen is 0
draft is 0
udate is OK
-===DONE===
echo "\n-- Testing imap_fetch_overview() function with less than expected no. of arguments --\n";
var_dump( imap_fetch_overview($stream_id) );
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Warning: imap_fetch_overview() expects at least 2 parameters, 1 given in %s on line %d
NULL
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Testing with option value:int(-%d)
Warning: imap_fetch_overview(): invalid value for the options parameter in %s on line %d
-===DONE===
// clear error stack
imap_errors();
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
seen is 0
draft is 0
udate is OK
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
seen is 0
draft is 0
udate is OK
-===DONE===
echo "Seen Flag: ";
var_dump( $overview[0]->seen );
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
-- Mandatory arguments --
string(36) "message 2:yyyyyyyyyyyyyyyyyyyyyyyyyy"
Seen Flag: int(%d)
-===DONE===
var_dump( imap_fetchbody($stream_id, $msg_no) );
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Warning: imap_fetchbody() expects at least 3 parameters, 2 given in %s on line %d
NULL
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Warning: imap_fetchbody(): invalid value for the options parameter in %s on line %d
FT_UID not valid
-===DONE===
}
}
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Notice: A non well formed numeric value encountered in %s on line %d
string(%d) "1: this is a test message, please ignore%a"
-===DONE===
echo "\n-- Mandatory arguments --\n";
var_dump( imap_fetchheader($stream_id, $msg_no) );
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Content-Type: %s; %s
"
-===DONE===
imap_close($stream_id);
?>
-===DONE===
--EXPECTF--
*** Testing imap_fetchheader() : error conditions ***
Warning: imap_fetchheader() expects at least 2 parameters, 1 given in %s on line %d
NULL
-===DONE===
$iterator++;
}
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Warning: imap_fetchheader(): invalid value for the options parameter in %s on line %d
FT_UID not valid
-===DONE===
// clear error stack
imap_errors();
?>
-===DONE===
--CLEAN--
<?php
require_once(__DIR__.'/clean.inc');
Content-Type: MULTIPART/mixed; BOUNDARY="%s"
"
-===DONE===
imap_close($stream_id);
?>
-===Done===
--EXPECTF--
Checking with no parameters
Warning: imap_mail_copy() expects at least 3 parameters, 2 given in %s on line %d
NULL
-===Done===
imap_close($imap_stream);
?>
-===Done===
--CLEAN--
<?php
require_once('clean.inc');
.. mailbox '%s' created
Msg Count in new mailbox: 1
bool(true)
-===Done===
imap_close($stream_id);
?>
-===Done===
--EXPECTF--
Checking with no parameters
Warning: imap_mail_move() expects at least 3 parameters, 2 given in %s on line %d
NULL
-===Done===
imap_close($imap_stream);
?>
-===Done===
--CLEAN--
<?php
require_once('clean.inc');
.. mailbox '%s' created
Msg Count in new mailbox: 1
bool(true)
-===Done===
print_r(iterator_to_array($codepoint_it));
?>
-==DONE==
--EXPECT--
string(26) "IntlCodePointBreakIterator"
Array
[14] => 42
[15] => 45
)
-==DONE==
var_dump($bi->next());
var_dump($bi->current());
?>
-==DONE==
--EXPECT--
int(0)
int(0)
int(0)
int(3)
int(3)
-==DONE==
var_dump($bi->following(50));
var_dump($bi->following(-1));
?>
-==DONE==
--EXPECT--
int(7)
int(-1)
int(0)
-==DONE==
var_dump($bi->getLocale(0));
var_dump($bi->getLocale(1));
?>
-==DONE==
--EXPECT--
string(4) "root"
string(4) "root"
-==DONE==
var_dump($bi->getLocale(0));
var_dump($bi->getLocale(1));
?>
-==DONE==
--EXPECT--
string(4) "root"
string(2) "pt"
-==DONE==
var_dump($bi->getLocale(0));
var_dump($bi->getLocale(1));
?>
-==DONE==
--EXPECT--
string(0) ""
string(2) "pt"
-==DONE==
print_r(iterator_to_array($pi));
var_dump($pi->getRuleStatus());
?>
-==DONE==
--EXPECT--
string(17) "IntlPartsIterator"
Array
[2] => bar
)
int(0)
-==DONE==
print_r(iterator_to_array($pi));
var_dump($pi->getRuleStatus());
?>
-==DONE==
--EXPECTF--
string(17) "IntlPartsIterator"
Array
[2] => bar
)
int(%d)
-==DONE==
var_dump($it->getPartsIterator(-1));
?>
-==DONE==
--EXPECTF--
Warning: IntlBreakIterator::getPartsIterator(): breakiter_get_parts_iterator: bad key type in %s on line %d
bool(false)
-==DONE==
var_dump(iterator_to_array($it->getPartsIterator(IntlPartsIterator::KEY_RIGHT)));
?>
-==DONE==
--EXPECT--
array(5) {
[0]=>
[12]=>
string(3) "tao"
}
-==DONE==
var_dump($bi->isBoundary(1));
var_dump($bi->isBoundary(50));
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
bool(false)
bool(false)
bool(false)
-==DONE==
var_dump($bi->next(0));
var_dump($bi->next(NULL));
?>
-==DONE==
--EXPECT--
int(0)
int(3)
int(4)
int(4)
int(7)
-==DONE==
var_dump($bi->preceding(50));
var_dump($bi->preceding(-1));
?>
-==DONE==
--EXPECT--
int(4)
int(21)
int(0)
-==DONE==
var_dump($bi->preceding(50));
var_dump($bi->preceding(-1));
?>
-==DONE==
--EXPECTF--
int(4)
int(21)
int(%i)
-==DONE==
var_dump($bi->last());
var_dump($bi->previous());
?>
-==DONE==
--EXPECT--
int(13)
int(8)
-==DONE==
var_dump($f->format(0.26));
?>
-==DONE==
--EXPECTF--
string(%d) "5,50 kr%A"
string(%d) "5,50 kr%A"
string(%d) "5,00 kr%A"
string(5) "23,25"
string(3) "26%"
-==DONE==
*/
?>
-==DONE==
--EXPECT--
date: Tuesday, July 7, 2009 8:41:13 PM EDT
msgf: Tuesday, July 7, 2009 8:41:13 PM EDT
-==DONE==
*/
?>
-==DONE==
--EXPECT--
date: Tuesday, July 7, 2009 8:41:13 PM EDT
msgf: Tuesday, July 7, 2009 8:41:13 PM usnyc
-==DONE==
var_dump(grapheme_substr(implode("\r\n", ['abc', 'def', 'ghi']), 5));
var_dump(grapheme_strrpos("a\r\nb", 'b'));
?>
-==DONE==
--EXPECT--
int(1)
string(7) "ef
ghi"
int(2)
-==DONE==
echo IntlDateFormatter::formatObject($date, $pattern1, 'vi_VN'), "\n";
echo IntlDateFormatter::formatObject ($date, $pattern2, 'ko_KR'), "\n";
?>
-==DONE==
--EXPECT--
tháng 04, 2015
2015년 4월
-==DONE==
echo IntlDateFormatter::formatObject($date, array(IntlDateFormatter::SHORT, IntlDateFormatter::NONE), 'vi_VN'), "\n";
echo IntlDateFormatter::formatObject ($date, array(IntlDateFormatter::SHORT, IntlDateFormatter::NONE), 'ko_KR'), "\n";
?>
-==DONE==
--EXPECT--
04/04/2015
15. 4. 4.
-==DONE==
var_dump($rm->getNumberOfParameters());
var_dump($rm->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(2)
int(1)
int(2)
int(1)
-===DONE===
var_dump($rf->getNumberOfParameters());
var_dump($rf->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(1)
int(2)
int(2)
-===DONE===
var_dump(MessageFormatter::formatMessage('en_US', $text, $vars));
?>
-==DONE==
--EXPECT--
string(26) "1 2 3 4 5 6 7 8 9 10 11 12"
-==DONE==
var_dump($rf->getNumberOfParameters());
var_dump($rf->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(1)
int(2)
int(2)
-===DONE===
count($intlGregorianCalendarRef->getConstants()) === count($intlCalendarRef->getConstants())
);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
$b = [new stdclass, new stdclass];
var_dump($a->sort($b));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
$rm = new ReflectionMethod('UConverter', 'getAliases');
var_dump($rm->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(1)
-===DONE===
$it->setText('foo');
var_dump($it);
?>
-===DONE===
--EXPECTF--
object(IntlRuleBasedBreakIterator)#%d (3) {
["valid"]=>
["type"]=>
string(%d) "%SRuleBasedBreakIterator%S"
}
-===DONE===
$intlcal->getTime());
?>
-==DONE==
--EXPECT--
float(1330578367000)
-float(1330578367000)
-==DONE==\r
\ No newline at end of file
+float(1330578367000)\r
\ No newline at end of file
var_dump($intlcal2->getTime());
?>
-==DONE==
--EXPECT--
bool(true)
int(1970)
int(0)
int(0)
int(0)
-float(-3600000)
-==DONE==\r
\ No newline at end of file
+float(-3600000)\r
\ No newline at end of file
strtotime('2012-01-29 05:06:07 +0000') * 1000.
);
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
bool(false)
float(1327813567000)
-float(1327813567000)
-==DONE==\r
\ No newline at end of file
+float(1327813567000)\r
\ No newline at end of file
var_dump(abs($timeMillis - $time * 1000) < 2000);
?>
-==DONE==
--EXPECTF--
IntlTimeZone Object
(
nl
gregorian
bool(true)
-==DONE==
echo "\n";
?>
-==DONE==
--EXPECTF--
IntlTimeZone Object
(
[currentOffset] => %d
)
pt
-==DONE==
var_dump("3 after 2", intlcal_after($intlcal3, $intlcal2));
?>
-==DONE==
--EXPECT--
string(8) "japanese"
string(6) "1 eq 1"
string(10) "3 before 2"
bool(false)
string(9) "3 after 2"
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
strtotime('2012-02-29 06:07:08 +0000') * 1000,
IntlCalendar::FIELD_MINUTE));
?>
-==DONE==
--EXPECT--
int(3601)
int(6)
-int(61)
-==DONE==\r
\ No newline at end of file
+int(61)\r
\ No newline at end of file
var_dump(in_array('pt', $locales));
?>
-==DONE==
--EXPECT--
bool(true)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
);
?>
-==DONE==
--EXPECT--
int(3)
int(0)
int(0)
int(0)
int(1)
-==DONE==
);
?>
-==DONE==
--EXPECT--
int(1)
int(0)
int(0)
int(0)
int(1)
-==DONE==
intlcal_get_error_message($intlcal)
);
?>
-==DONE==
--EXPECTF--
int(0)
int(0)
int(1)
string(81) "intlcal_field_difference: Call to ICU method has failed: U_ILLEGAL_ARGUMENT_ERROR"
string(81) "intlcal_field_difference: Call to ICU method has failed: U_ILLEGAL_ARGUMENT_ERROR"
-==DONE==
var_dump($intlcal->getFirstDayOfWeek());
var_dump(intlcal_get_first_day_of_week($intlcal));
?>
-==DONE==
--EXPECT--
int(2)
-int(2)
-==DONE==\r
\ No newline at end of file
+int(2)\r
\ No newline at end of file
var_dump(in_array('japanese', $var));
?>
-==DONE==
--EXPECT--
Array
(
bool(true)
bool(true)
-==DONE==
var_dump($intlcal->getLocale(Locale::ACTUAL_LOCALE));
var_dump(intlcal_get_locale($intlcal, Locale::VALID_LOCALE));
?>
-==DONE==
--EXPECT--
string(2) "nl"
string(5) "nl_NL"
-==DONE==
var_dump($intlcal->getMinimalDaysInFirstWeek());
var_dump(intlcal_get_minimal_days_in_first_week($intlcal));
?>
-==DONE==
--EXPECT--
int(4)
int(4)
-==DONE==
var_dump(abs($time * 1000 - $proc_now) < 2000);
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
-==DONE==
print_r($intlcal->getTimeZone());
print_r(intlcal_get_time_zone($intlcal));
?>
-==DONE==
--EXPECT--
IntlTimeZone Object
(
[rawOffset] => 60000
[currentOffset] => 60000
)
-==DONE==
var_dump((float)$time*1000, $intlcal->getTime());
?>
-==DONE==
--EXPECT--
float(1330473600000)
-float(1330473600000)
-==DONE==\r
\ No newline at end of file
+float(1330473600000)\r
\ No newline at end of file
$intlcal = IntlCalendar::createInstance(null, "nl_NL@calendar=hebrew");
VAR_DUMP(intlcal_get_type($intlcal));
?>
-==DONE==
--EXPECT--
string(9) "gregorian"
-string(6) "hebrew"
-==DONE==\r
\ No newline at end of file
+string(6) "hebrew"\r
\ No newline at end of file
var_dump($intlcal->getWeekendTransition(IntlCalendar::DOW_SUNDAY));
var_dump(intlcal_get_weekend_transition($intlcal, IntlCalendar::DOW_SUNDAY));
?>
-==DONE==
--EXPECT--
int(86400000)
int(86400000)
-==DONE==
);
?>
-==DONE==
--EXPECT--
int(28)
int(28)
int(29)
int(29)
int(31)
-int(31)
-==DONE==\r
\ No newline at end of file
+int(31)\r
\ No newline at end of file
);
?>
-==DONE==
--EXPECT--
int(1)
int(1)
int(1)
int(1)
int(1)
-int(1)
-==DONE==\r
\ No newline at end of file
+int(1)\r
\ No newline at end of file
var_dump(intlcal_get($intlcal, IntlCalendar::FIELD_DAY_OF_MONTH));
?>
-==DONE==
--EXPECT--
int(4)
-int(4)
-==DONE==\r
\ No newline at end of file
+int(4)\r
\ No newline at end of file
);
?>
-==DONE==
--EXPECT--
bool(true)
int(0)
int(1)
int(1351384200)
int(1351384200)
-==DONE==
?>
-==DONE==
--EXPECT--
int(0)
Should be 3h30
Should be 3h00
int(3)
int(0)
-==DONE==
$intlcal->setTime(strtotime('2012-04-01') * 1000);
var_dump(intlcal_in_daylight_time($intlcal));
?>
-==DONE==
--EXPECT--
bool(false)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
);
?>
-==DONE==
--EXPECT--
string(5) "1 - 1"
bool(true)
string(5) "1 - 3"
bool(false)
string(5) "1 - 4"
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
$intlcal->set(IntlCalendar::FIELD_MINUTE, 0);
var_dump(intlcal_is_set($intlcal, IntlCalendar::FIELD_MINUTE));
?>
-==DONE==
--EXPECT--
bool(true)
bool(false)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
var_dump(intlcal_is_weekend($intlcal, strtotime('2012-02-29 12:00:00 +0000') * 1000));
var_dump($intlcal->isWeekend(strtotime('2012-03-11 12:00:00 +0000') * 1000));
?>
-==DONE==
--EXPECT--
bool(false)
bool(false)
bool(true)
-==DONE==
var_dump(intlcal_set_lenient($intlcal1, true));
var_dump($intlcal1->isLenient());
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
bool(true)
bool(false)
bool(true)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
?>
-==DONE==
--EXPECT--
bool(true)
int(1)
int(1)
bool(true)
int(1)
-int(1)
-==DONE==\r
\ No newline at end of file
+int(1)\r
\ No newline at end of file
var_dump($intlcal->get(IntlCalendar::FIELD_DAY_OF_MONTH)); //28
?>
-==DONE==
--EXPECT--
bool(true)
int(1)
int(29)
bool(true)
int(1)
-int(28)
-==DONE==\r
\ No newline at end of file
+int(28)\r
\ No newline at end of file
$intlcal->getFirstDayOfWeek()
);
?>
-==DONE==
--EXPECT--
int(3)
bool(true)
int(3)
bool(true)
-int(4)
-==DONE==\r
\ No newline at end of file
+int(4)\r
\ No newline at end of file
$intlcal->getMinimalDaysInFirstWeek()
);
?>
-==DONE==
--EXPECT--
bool(true)
int(6)
bool(true)
int(5)
-==DONE==
var_dump($intlcal->get(IntlCalendar::FIELD_ZONE_OFFSET));
?>
-==DONE==
--EXPECT--
Europe/Amsterdam
int(3600000)
int(0)
GMT+05:30
int(19800000)
-==DONE==
var_dump($intlcal->get(IntlCalendar::FIELD_ZONE_OFFSET));
?>
-==DONE==
--EXPECT--
Europe/Amsterdam
int(3600000)
Europe/Amsterdam
-int(3600000)
-==DONE==\r
\ No newline at end of file
+int(3600000)\r
\ No newline at end of file
var_dump(intlcal_get_time($intlcal));
?>
-==DONE==
--EXPECT--
float(1330473600000)
float(1330473600000)
-float(1330473600000)
-==DONE==\r
\ No newline at end of file
+float(1330473600000)\r
\ No newline at end of file
var_dump($intlcal->get(IntlCalendar::FIELD_DAY_OF_MONTH));
?>
-==DONE==
--EXPECT--
bool(true)
int(2)
bool(true)
-int(3)
-==DONE==\r
\ No newline at end of file
+int(3)\r
\ No newline at end of file
strtotime('2012-02-29 23:58:31 +0000') * 1000.);
?>
-==DONE==
--EXPECT--
bool(true)
float(1330473600000)
float(1330559880000)
bool(true)
float(1330559911000)
-float(1330559911000)
-==DONE==\r
\ No newline at end of file
+float(1330559911000)\r
\ No newline at end of file
var_dump($dt->format("c"), $dt->getTimeZone()->getName());
?>
-==DONE==
--EXPECT--
string(25) "2012-05-17T17:35:36+01:00"
string(13) "Europe/Lisbon"
-==DONE==
var_dump($it == $it_clone);
?>
-==DONE==
--EXPECT--
bool(true)
bool(false)
bool(true)
-==DONE==
?>
-==DONE==
--EXPECT--
int(-1)
int(-1)
string(6) "U+0E27"
string(6) "U+0E31"
string(6) "U+0E15"
-==DONE==
}
?>
-==DONE==
--EXPECT--
0. ต (U+0E15) at 3
1. ั (U+0E31) at 6
12. ว (U+0E27) at 39
13. า (U+0E32) at 42
14. ม (U+0E21) at 45
-==DONE==
print_exception($e);
}
?>
-==DONE==
--EXPECTF--
Exception: IntlDateFormatter::__construct(): datefmt_create: no such time zone: 'bad timezone' in %s on line %d
Exception: IntlDateFormatter::__construct(): datefmt_create: invalid value for calendar type; it must be one of IntlDateFormatter::TRADITIONAL (locale's default calendar) or IntlDateFormatter::GREGORIAN. Alternatively, it can be an IntlCalendar object in %s on line %d
Exception: IntlDateFormatter::__construct(): datefmt_create: Invalid calendar argument; should be an integer or an IntlCalendar instance in %s on line %d
-==DONE==
var_dump($formatter->format(new DateTimeImmutable('2017-03-27 00:00:00 UTC'))) . "\n";
?>
-==DONE==
--EXPECTF--
string(%s) "Monday, March %d, 2017"
-==DONE==
echo "Formatter with pattern set later: " . $badFormatter2->getLocale() . PHP_EOL;
?>
-==DONE==
--EXPECT--
Formatter without pattern: ru
Formatter with pattern: ru
Formatter with pattern set later: ru
-==DONE==
echo $df->format($ts), "\n";
?>
-==DONE==
--EXPECTF--
domingo%S 1 de enero de 2012 00:00:00 GMT
domingo%S 8 de Safar de 1433 00:00:00 GMT
sábado%S 7 de Safar de 1433 AH 23:00:00 Hora %Sde las Azores
domingo%S 8 de Safar de 1433 AH 00:00:00 GMT
domingo%S 1 de enero de 2012 00:00:00 GMT
-==DONE==
echo $df->format($ts), "\n";
?>
-==DONE==
--EXPECTF--
domingo%S 1 de enero de 2012 00:00:00 GMT
domingo%S 8 de Safar de 1433 00:00:00 GMT
sábado%S 7 de Safar de 1433 AH 23:00:00 Hora %Sde las Azores
domingo%S 8 de Safar de 1433 AH 00:00:00 GMT
domingo%S 1 de enero de 2012 00:00:00 GMT
-==DONE==
echo $df->format($ts), "\n";
?>
-==DONE==
--EXPECTF--
domingo%S 1 de enero de 2012, 0:00:00 (GMT)
domingo%S 8 de Safar de 1433, 0:00:00 (GMT)
sábado%S 7 de Safar de 1433 AH, 23:00:00 (Hora estándar %Sde las Azores)
domingo%S 8 de Safar de 1433 AH, 0:00:00 (GMT)
domingo%S 1 de enero de 2012, 0:00:00 (GMT)
-==DONE==
echo $df->format($ts), "\n";
?>
-==DONE==
--EXPECTF--
domingo%S 1 de enero de 2012, 0:00:00 (GMT)
domingo%S 8 de Safar de 1433, 0:00:00 (GMT)
sábado, 7 de Safar de 1433 AH, 23:00:00 (hora estándar de las Azores)
domingo%S 8 de Safar de 1433 AH, 0:00:00 (GMT)
domingo%S 1 de enero de 2012, 0:00:00 (GMT)
-==DONE==
echo $df->format($ts), "\n";
?>
-==DONE==
--EXPECTF--
domingo%S 1 de enero de 2012, 0:00:00 (%siempo %sniversal %sordinado)
domingo%S 8 de %safar de 1433, 0:00:00 (%siempo %sniversal %sordinado)
sábado, 7 de %safar de 1433 AH, 23:00:00 (hora estándar de las Azores)
domingo%S 8 de %safar de 1433 AH, 0:00:00 (%siempo %sniversal %sordinado)
domingo%S 1 de enero de 2012, 0:00:00 (%siempo %sniversal %sordinado)
-==DONE==
echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012 00:00:00
Domingo, 1 de Janeiro de 2012 0:00:00 Hora %Sda Europa Ocidental
Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00
06/02/1433 00:00:00
Sunday, Safar 6, 1433 12:00:00 AM Western European %STime
-==DONE==
echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
Domingo, 1 de Janeiro de 2012 às 00:00:00 Hora %Sda Europa Ocidental
Domingo, 1 de Janeiro de 2012 às 05:00:00 GMT+03:00
06/02/1433, 00:00:00
Sunday, Safar 6, 1433 at 12:00:00 AM Western European Standard Time
-==DONE==
echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
domingo, 1 de Janeiro de 2012 às 00:00:00 Hora Padrão %Sda Europa Ocidental
domingo, 1 de Janeiro de 2012 às 05:00:00 GMT+03:00
06/02/1433, 00:00:00
Sunday, Safar 6, 1433 at 12:00:00 AM Western European Standard Time
-==DONE==
echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
domingo, 1 de janeiro de 2012 às 00:00:00 Hora Padrão %Sda Europa Ocidental
domingo, 1 de janeiro de 2012 às 05:00:00 GMT+03:00
06/02/1433, 00:00:00
Sunday, Safar 6, 1433 at 12:00:00 AM Western European Standard Time
-==DONE==
echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
domingo, 1 de janeiro de 2012 às 00:00:00 Hora padrão %Sda Europa Ocidental
domingo, 1 de janeiro de 2012 às 05:00:00 GMT+03:00
06/02/1433, 00:00:00
Sunday, Safar 6, 1433 at 12:00:00 AM Western European Standard Time
-==DONE==
echo IntlDateFormatter::formatObject($dt, IntlDateFormatter::FULL), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012 00:00:00
Domingo, 1 de Janeiro de 2012 0:00:00 Hora %Sda Europa Ocidental
1/1/12 12:00:00 AM Western European %STime
Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon)
Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00
-==DONE==
echo IntlDateFormatter::formatObject($dt, IntlDateFormatter::FULL), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
Domingo, 1 de Janeiro de 2012 às 00:00:00 Hora %Sda Europa Ocidental
1/1/12, 12:00:00 AM Western European Standard %STime
Sun 2012-01-1 00,00,00.000 Portugal Time
Domingo, 1 de Janeiro de 2012 às 05:00:00 GMT+03:00
-==DONE==
echo IntlDateFormatter::formatObject($dt, IntlDateFormatter::FULL), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
domingo, 1 de Janeiro de 2012 às 00:00:00 Hora Padrão %Sda Europa Ocidental
1/1/12, 12:00:00 AM Western European Standard %STime
Sun 2012-01-1 00,00,00.000 Portugal Time
domingo, 1 de Janeiro de 2012 às 05:00:00 GMT+03:00
-==DONE==
echo IntlDateFormatter::formatObject($dt, IntlDateFormatter::FULL), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
domingo, 1 de janeiro de 2012 às 00:00:00 Hora Padrão %Sda Europa Ocidental
1/1/12, 12:00:00 AM Western European Standard %STime
Sun 2012-01-1 00,00,00.000 Portugal Time
domingo, 1 de janeiro de 2012 às 05:00:00 GMT+03:00
-==DONE==
echo IntlDateFormatter::formatObject($dt, IntlDateFormatter::FULL), "\n";
?>
-==DONE==
--EXPECTF--
01/01/2012, 00:00:00
domingo, 1 de janeiro de 2012 às 00:00:00 Hora padrão %Sda Europa Ocidental
1/1/12, 12:00:00 AM Western European Standard %STime
Sun 2012-01-1 00,00,00.000 Portugal Time
domingo, 1 de janeiro de 2012 às 05:00:00 GMT+03:00
-==DONE==
var_dump(IntlDateFormatter::formatObject($cal, ""));
?>
-==DONE==
--EXPECTF--
Warning: IntlDateFormatter::formatObject(): datefmt_format_object: the passed object must be an instance of either IntlCalendar or DateTime in %s on line %d
bool(false)
Warning: IntlDateFormatter::formatObject(): datefmt_format_object: the format is empty in %s on line %d
bool(false)
-==DONE==
d($df);
?>
-==DONE==
--EXPECT--
dimanche 1 janvier 2012 ap. J.-C. 03:00:00 UTC+03:00
int(1)
string(9) "gregorian"
string(3) "UTC"
-==DONE==
d($df);
?>
-==DONE==
--EXPECT--
dimanche 1 janvier 2012 ap. J.-C. 03:00:00 UTC+03:00
int(1)
string(9) "gregorian"
string(3) "UTC"
-==DONE==
d($df);
?>
-==DONE==
--EXPECT--
dimanche 1 janvier 2012 ap. J.-C. à 03:00:00 UTC+03:00
int(1)
string(9) "gregorian"
string(3) "UTC"
-==DONE==
d($df);
?>
-==DONE==
--EXPECT--
dimanche 1 janvier 2012 ap. J.-C. à 03:00:00 heure de Kaliningrad
int(1)
string(9) "gregorian"
string(3) "UTC"
-==DONE==
d($df);
?>
-==DONE==
--EXPECT--
dimanche 1 janvier 2012 ap. J.-C. à 03:00:00 heure de Kaliningrad
int(1)
string(9) "gregorian"
string(3) "UTC"
-==DONE==
d($df);
?>
-==DONE==
--EXPECTF--
Domingo, 1 de Janeiro de 2012 3:00:00 GMT+03:00
string(12) "Europe/Minsk"
string(16) "Europe/Amsterdam"
string(16) "Europe/Amsterdam"
-==DONE==
d($df);
?>
-==DONE==
--EXPECTF--
Domingo, 1 de Janeiro de 2012 às 03:00:00 GMT+03:00
string(12) "Europe/Minsk"
string(16) "Europe/Amsterdam"
string(16) "Europe/Amsterdam"
-==DONE==
d($df);
?>
-==DONE==
--EXPECTF--
domingo, 1 de Janeiro de 2012 às 03:00:00 GMT+03:00
string(12) "Europe/Minsk"
string(16) "Europe/Amsterdam"
string(16) "Europe/Amsterdam"
-==DONE==
d($df);
?>
-==DONE==
--EXPECTF--
domingo, 1 de janeiro de 2012 às 03:00:00 Hor%s do Extremo Leste da Europa
string(12) "Europe/Minsk"
string(16) "Europe/Amsterdam"
string(16) "Europe/Amsterdam"
-==DONE==
d($df);
?>
-==DONE==
--EXPECTF--
domingo, 1 de janeiro de 2012 às 03:00:00 Hor%s do Extremo Leste da Europa
string(12) "Europe/Minsk"
string(16) "Europe/Amsterdam"
string(16) "Europe/Amsterdam"
-==DONE==
var_dump($df->setTimeZone('non existing timezone'));
?>
-==DONE==
--EXPECTF--
Warning: Array to string conversion in %s on line %d
Warning: IntlDateFormatter::setTimeZone(): datefmt_set_timezone: no such time zone: 'non existing timezone' in %s on line %d
bool(false)
-==DONE==
var_dump($intlcal->getType());
?>
-==DONE==
--EXPECT--
string(16) "Europe/Amsterdam"
string(5) "nl_NL"
string(12) "Europe/Paris"
string(5) "fr_CA"
string(9) "gregorian"
-==DONE==
var_dump($intlcal->getType());
?>
-==DONE==
--EXPECT--
string(16) "Europe/Amsterdam"
float(1330527600000)
float(1330528028000)
float(1330528028000)
string(9) "gregorian"
-==DONE==
var_dump($intlcal->getGregorianChange());
?>
-==DONE==
--EXPECT--
float(-12219292800000)
bool(true)
float(0)
bool(true)
-float(1)
-==DONE==\r
\ No newline at end of file
+float(1)\r
\ No newline at end of file
var_dump(intlgregcal_is_leap_year($intlcal, 2012));
var_dump(intlgregcal_is_leap_year($intlcal, 1900));
?>
-==DONE==
--EXPECT--
bool(true)
bool(false)
bool(true)
-bool(false)
-==DONE==\r
\ No newline at end of file
+bool(false)\r
\ No newline at end of file
var_dump(locale_lookup($availableLocales, false, true));
?>
-==DONE==
--EXPECT--
string(5) "fr_fr"
string(5) "en_us"
string(5) "fr_fr"
string(5) "de_de"
-==DONE==
);
?>
-==DONE==
--EXPECT--
string(5) "de-DE"
string(5) "de-DE"
-==DONE==
printf("%s: %d, %d\n", $method, $rm->getNumberOfParameters(), $rm->getNumberOfRequiredParameters());
}
?>
-===DONE===
--EXPECT--
getDefault: 0, 0
acceptFromHttp: 1, 1
getDisplayVariant: 2, 1
filterMatches: 3, 2
lookup: 4, 2
-===DONE===
}
?>
-==DONE==
--EXPECTF--
de string key
string(8) "42-other"
string(26) "2 147 483 643,123-other"
string(4) "five"
-==DONE==
var_dump($mf->format(array($dti)));
?>
-==DONE==
--EXPECTF--
string(%s) "May %d, 2012 %d:%d:42 %s"
string(%s) "May %d, 2012 %d:%d:42 %s"
-==DONE==
*/
?>
-==DONE==
--EXPECT--
Quinta-feira, 17 de Maio de 2012 5:35:36 p.m. WEST
-==DONE==
*/
?>
-==DONE==
--EXPECT--
Quinta-feira, 17 de Maio de 2012 5:35:36 PM ptlis
-==DONE==
*/
?>
-==DONE==
--EXPECT--
quinta-feira, 17 de Maio de 2012 5:35:36 da tarde ptlis
-==DONE==
*/
?>
-==DONE==
--EXPECT--
quinta-feira, 17 de maio de 2012 5:35:36 da tarde ptlis
-==DONE==
var_dump($mf->format(array("foo" => 1.3, 0 => 2.3)));
?>
-==DONE==
--EXPECT--
string(10) "2.3 -- 1st"
string(10) "2.3 -- 1st"
-==DONE==
)));
?>
-==DONE==
--EXPECTF--
string(%d) "
none 1336317965.5 str
ordinal 1,336,317,966th
duration 371,199:26:06
"
-==DONE==
var_dump($mf->parse($p));
?>
-==DONE==
--EXPECTF--
string(%d) "On 2012-05-0%d AD at %d:%d:49.123 %s something odd happened"
array(1) {
[0]=>
float(1336310569.123)
}
-==DONE==
var_dump($mf->format(array(1.3, 1.3)));
?>
-==DONE==
--EXPECT--
string(10) "1.3 -- 1st"
string(10) "1.3 -- 1st"
string(10) "1st -- 1.3"
-==DONE==
}
?>
-==DONE==
--EXPECT--
string(26) "IntlRuleBasedBreakIterator"
int(1)
string(93) "rbbi_create_instance: unable to create instance from compiled rules: U_ILLEGAL_ARGUMENT_ERROR"
-==DONE==
var_dump($rbbi->getRules(), $rbbi2->getRules());
var_dump($rbbi->getRules() == $rbbi2->getRules());
?>
-==DONE==
--EXPECT--
string(128) "$LN = [[:letter:] [:number:]];$S = [.;,:];!!forward;$LN+ {1};$S+ {42};!!reverse;$LN+ {1};$S+ {42};!!safe_forward;!!safe_reverse;"
string(128) "$LN = [[:letter:] [:number:]];$S = [.;,:];!!forward;$LN+ {1};$S+ {42};!!reverse;$LN+ {1};$S+ {42};!!safe_forward;!!safe_reverse;"
bool(true)
-==DONE==
var_dump($rbbi->getRules(), $rbbi2->getRules());
var_dump($rbbi->getRules() == $rbbi2->getRules());
?>
-==DONE==
--EXPECT--
string(137) "$LN = [[:letter:] [:number:]];
$S = [.;,:];
!!safe_forward;
!!safe_reverse;"
bool(true)
-==DONE==
} while ($rbbi->next() != IntlBreakIterator::DONE);
?>
-==DONE==
--EXPECT--
int(0)
array(1) {
[0]=>
int(4)
}
-==DONE==
} while ($rbbi->next() != IntlBreakIterator::DONE);
?>
-==DONE==
--EXPECT--
pos : 0
rule status: 0
rule status: 0
pos : 19
rule status: 42
-==DONE==
var_dump($rbbi->getRules());
?>
-==DONE==
--EXPECT--
string(128) "$LN = [[:letter:] [:number:]];$S = [.;,:];!!forward;$LN+ {1};$S+ {42};!!reverse;$LN+ {1};$S+ {42};!!safe_forward;!!safe_reverse;"
-==DONE==
var_dump($rbbi->getRules());
?>
-==DONE==
--EXPECT--
string(137) "$LN = [[:letter:] [:number:]];
$S = [.;,:];
$S+ {42};
!!safe_forward;
!!safe_reverse;"
-==DONE==
$c = $r->get('calendar')->get('gregorian')->get('DateTimePatterns')->get(0);
var_dump($c);
?>
-==DONE==
--EXPECT--
string(14) "h:mm:ss a zzzz"
string(12) "H:mm:ss zzzz"
-==DONE==
$c = $r->get('calendar')->get('gregorian')->get('DateTimePatterns')->get(0);
var_dump($c);
?>
-==DONE==
--EXPECT--
string(14) "h:mm:ss a zzzz"
string(13) "HH:mm:ss zzzz"
-==DONE==
print_r(clone $gmt);
?>
-==DONE==
--EXPECTF--
IntlTimeZone Object
(
[id] => GMT
[rawOffset] => 0
[currentOffset] => 0
-)
-==DONE==\r
\ No newline at end of file
+)\r
\ No newline at end of file
}
?>
-==DONE==
--EXPECT--
object(A)#1 (1) {
["valid"]=>
bool(false)
}
string(9) "Exception"
-string(39) "Cannot clone unconstructed IntlTimeZone"
-==DONE==\r
\ No newline at end of file
+string(39) "Cannot clone unconstructed IntlTimeZone"\r
\ No newline at end of file
$count2 = intltz_count_equivalent_ids('Europe/Lisbon');
var_dump($count2 == $count);
?>
-==DONE==
--EXPECT--
bool(true)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
$tz = intltz_create_default();
print_r($tz);
?>
-==DONE==
--EXPECTF--
IntlTimeZone Object
(
[rawOffset] => %i
[currentOffset] => %i
)
-==DONE==
$count2 = count(iterator_to_array($tz));
var_dump($count == $count2);
?>
-==DONE==
--EXPECT--
string(12) "IntlIterator"
bool(true)
string(12) "IntlIterator"
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
var_dump(in_array('Europe/Amsterdam', iterator_to_array($tz)));
?>
-==DONE==
--EXPECT--
string(12) "IntlIterator"
bool(true)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
var_dump(in_array('Europe/Amsterdam', iterator_to_array($tz)));
?>
-==DONE==
--EXPECT--
string(12) "IntlIterator"
bool(true)
-bool(true)
-==DONE==\r
\ No newline at end of file
+bool(true)\r
\ No newline at end of file
-3600000);
print_r(iterator_to_array($enum));
?>
-==DONE==
--EXPECT--
Array
(
(
[0] => Atlantic/Azores
)
-==DONE==
var_dump($values2 == $values);
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
bool(true)
-==DONE==
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
[0] => Atlantic/Azores
[1] => Etc/GMT+1
)
-==DONE==
$tz = intltz_create_time_zone('GMT+01:00');
print_r($tz);
?>
-==DONE==
--EXPECT--
IntlTimeZone Object
(
[rawOffset] => 3600000
[currentOffset] => 3600000
)
-==DONE==
var_dump($tz1 == intltz_get_gmt());
?>
-==DONE==
--EXPECT--
Comparison to self:
bool(true)
Comparison to equivalent instance:
bool(false)
Comparison to GMT:
-bool(false)
-==DONE==\r
\ No newline at end of file
+bool(false)\r
\ No newline at end of file
}
?>
-==DONE==
--EXPECT--
object(A)#1 (1) {
["valid"]=>
int(0)
}
string(9) "Exception"
-string(63) "Comparison with at least one unconstructed IntlTimeZone operand"
-==DONE==\r
\ No newline at end of file
+string(63) "Comparison with at least one unconstructed IntlTimeZone operand"\r
\ No newline at end of file
print_R(intltz_get_canonical_id('Portugal'));
echo "\n";
?>
-==DONE==
--EXPECT--
Europe/Lisbon
-Europe/Lisbon
-==DONE==\r
\ No newline at end of file
+Europe/Lisbon\r
\ No newline at end of file
var_dump($isSystemId);
?>
-==DONE==
--EXPECT--
string(13) "Europe/Lisbon"
bool(true)
string(0) ""
bool(false)
-==DONE==
var_dump($isSystemId);
?>
-==DONE==
--EXPECTF--
string(13) "Europe/Lisbon"
bool(true)
Warning: IntlTimeZone::getCanonicalID(): intltz_get_canonical_id: error obtaining canonical ID in %stimezone_getCanonicalID_variant1_2.php on line %d
bool(false)
bool(true)
-==DONE==
var_dump(intltz_get_dst_savings($lsb));
?>
-==DONE==
--EXPECT--
int(3600000)
-int(3600000)
-==DONE==\r
\ No newline at end of file
+int(3600000)\r
\ No newline at end of file
var_dump($lsb->getDisplayName());
?>
-==DONE==
--EXPECTF--
string(%d) "Western European%sTime"
-string(%d) "Hora%sda Europa Ocidental"
-==DONE==\r
\ No newline at end of file
+string(%d) "Hora%sda Europa Ocidental"\r
\ No newline at end of file
var_dump($lsb->getDisplayName(true));
?>
-==DONE==
--EXPECTF--
string(%d) "Western European%sTime"
string(%d) "Western European%sTime"
-string(28) "Western European Summer Time"
-==DONE==\r
\ No newline at end of file
+string(28) "Western European Summer Time"\r
\ No newline at end of file
var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_GENERIC_LOCATION));
?>
-==DONE==
--EXPECT--
string(3) "GMT"
string(30) "Western European Standard Time"
string(3) "GMT"
string(3) "GMT"
string(22) "Portugal Time (Lisbon)"
-==DONE==
var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_LONG, 'pt_PT'));
?>
-==DONE==
--EXPECTF--
string(30) "Western European Standard Time"
string(30) "Western European Standard Time"
string(32) "Hora %cadrão da Europa Ocidental"
-==DONE==
var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_GENERIC_LOCATION));
?>
-==DONE==
--EXPECT--
string(3) "GMT"
string(30) "Western European Standard Time"
string(3) "GMT"
string(3) "GMT"
string(13) "Portugal Time"
-==DONE==
print_R(intltz_get_equivalent_id('Europe/Lisbon', 1));
echo "\n";
?>
-==DONE==
--EXPECT--
Portugal
-Portugal
-==DONE==\r
\ No newline at end of file
+Portugal\r
\ No newline at end of file
var_dump($lsb->getErrorMessage());
?>
-==DONE==
--EXPECTF--
int(0)
string(12) "U_ZERO_ERROR"
bool(false)
int(1)
string(67) "intltz_get_offset: error obtaining offset: U_ILLEGAL_ARGUMENT_ERROR"
-==DONE==
$tz = intltz_get_gmt();
print_r($tz);
?>
-==DONE==
--EXPECT--
IntlTimeZone Object
(
[id] => GMT
[rawOffset] => 0
[currentOffset] => 0
-)
-==DONE==\r
\ No newline at end of file
+)\r
\ No newline at end of file
$rawOffset, $dstOffset);
?>
-==DONE==
--EXPECT--
bool(true)
int(3600000)
int(3600000)
bool(true)
int(0)
-int(3600000)
-==DONE==\r
\ No newline at end of file
+int(3600000)\r
\ No newline at end of file
var_dump(intltz_get_raw_offset($lsb));
?>
-==DONE==
--EXPECT--
int(3600000)
-int(0)
-==DONE==\r
\ No newline at end of file
+int(0)\r
\ No newline at end of file
print_R(intltz_get_region('Europe/Amsterdam'));
echo "\n";
?>
-==DONE==
--EXPECT--
NL
NL
-==DONE==
print_R(intltz_get_tz_data_version());
echo "\n";
?>
-==DONE==
--EXPECTF--
20%d%s
-20%d%s
-==DONE==\r
\ No newline at end of file
+20%d%s\r
\ No newline at end of file
$tz = intltz_get_unknown();
print_r($tz);
?>
-==DONE==
--EXPECT--
IntlTimeZone Object
(
[rawOffset] => 0
[currentOffset] => 0
)
-==DONE==
var_dump(intltz_has_same_rules($lsb, $azo));
?>
-==DONE==
--EXPECT--
Europe/Lisbon has same rules as itself:
bool(true)
bool(true)
Europe/Lisbon has same rules as Atlantic/Azores:
-bool(false)
-==DONE==\r
\ No newline at end of file
+bool(false)\r
\ No newline at end of file
var_dump(intltz_use_daylight_time($lsb));
var_dump(intltz_use_daylight_time($gmt));
?>
-==DONE==
--EXPECT--
bool(true)
bool(false)
bool(true)
-bool(false)
-==DONE==\r
\ No newline at end of file
+bool(false)\r
\ No newline at end of file
var_dump(json_decode('{ "": "": "" } }'));
?>
-===DONE===
--EXPECTF--
NULL
NULL
}
NULL
NULL
-===DONE===
var_dump(json_encode(array("\x80" => 1), JSON_PARTIAL_OUTPUT_ON_ERROR));
?>
-===DONE===
--EXPECT--
string(6) "{"":1}"
-===DONE===
var_dump(json_decode('[""]'));
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(0) ""
}
-===DONE===
}
?>
-===Done===
--EXPECTF--
*** Testing json_decode() : basic functionality ***
-- Iteration 1 --
}
array(0) {
}
-===Done===
var_dump(json_decode('"abc"', true, -1));
?>
-===Done===
--EXPECTF--
*** Testing json_decode() : error conditions ***
Warning: json_decode(): Depth must be greater than zero in %s on line %d
NULL
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing json_encode() : basic functionality ***
-- Iteration 1 --
bool(false)
-- Iteration 27 --
string(82) "{"MyInt":99,"MyFloat":123.45,"MyBool":true,"MyNull":null,"MyString":"Hello World"}"
-===Done===
var_dump(json_encode($utf8_string));
?>
-===Done===
--EXPECT--
*** Testing json_encode() : basic functionality with UTF-8 input***
string(103) ""\u65e5\u672c\u8a9e\u30c6\u30ad\u30b9\u30c8\u3067\u3059\u300201234\uff15\uff16\uff17\uff18\uff19\u3002""
-===Done===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userC,cn=userB,%s"
}
}
-===DONE===
ldap_get_values($link, $entry, "telephoneNumber")
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
["count"]=>
int(2)
}
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "dc=my-domain,%s"
}
}
-===DONE===
*/
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_add(): Unknown attribute in the data in %s on line %d
bool(false)
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "o=test_ldap_add_ext,%s"
}
}
-===DONE===
ldap_set_option($link, LDAP_OPT_PROTOCOL_VERSION, $protocol_version);
var_dump(ldap_bind($link));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
// Invalid DN syntax
var_dump(ldap_bind($link, "unexistingProperty=weirdValue,$user", $passwd));
?>
-===DONE===
--EXPECTF--
Warning: ldap_bind(): Unable to bind to server: Invalid credentials in %s on line %d
bool(false)
Warning: ldap_bind(): Unable to bind to server: Invalid DN syntax in %s on line %d
bool(false)
-===DONE===
$ctrls
);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (ldap result)
bool(true)
string(10) "invalid DN"
array(0) {
}
-===DONE===
ldap_set_option($link, LDAP_OPT_PROTOCOL_VERSION, $protocol_version);
var_dump(ldap_bind($link, $user, $passwd));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
ldap_compare($link, "cn=userA,$base", "telephoneNumber", "yy-yy-yy-yy-yy")
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
--EXPECT--
bool(true)
bool(false)
-===DONE===
ldap_errno($link)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
int(-1)
string(14) "No such object"
int(32)
-===DONE===
$link = ldap_connect($host, $port);
var_dump($link);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (ldap link)
-===DONE===
$links[0] = ldap_connect($host, $port);
$links[1] = ldap_connect($host, $port);
?>
-===DONE===
--EXPECTF--
Warning: ldap_connect(): Could not create session handle: %s in %s on line %d
bool(false)
Warning: ldap_connect(): Too many open links (1) in %s on line %d
-===DONE===
var_dump($host);
unlink($conf);
?>
-===DONE===
--EXPECT--
string(16) "example.com:3141"
-===DONE===
$link = ldap_connect("nonexistent" . $host);
var_dump($link);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (ldap link)
resource(%d) of type (ldap link)
resource(%d) of type (ldap link)
resource(%d) of type (ldap link)
resource(%d) of type (ldap link)
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userA,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userB,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userC,cn=userB,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)[0]['l']
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
[1]=>
string(5) "there"
}
-===DONE===
$result = ldap_search($link, "$base", "(objectclass=person)");
var_dump(ldap_count_entries($link, $result));
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
?>
--EXPECT--
int(3)
-===DONE===
@ldap_search($link, "dc=my-domain,$base", "(o=my-domain)")
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
--EXPECT--
bool(true)
bool(false)
-===DONE===
ldap_errno($link)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
bool(false)
string(14) "No such object"
int(32)
-===DONE===
@ldap_search($link, "dc=my-domain,$base", "(o=my-domain)")
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
}
}
bool(false)
-===DONE===
<?php
var_dump(ldap_err2str(2));
?>
-===DONE===
--EXPECT--
string(14) "Protocol error"
-===DONE===
ldap_errno($link)
);
?>
-===DONE===
--EXPECT--
int(34)
-===DONE===
ldap_error($link)
);
?>
-===DONE===
--EXPECT--
string(17) "Invalid DN syntax"
-===DONE===
test_bind($host, $port, "cn=userA,$base", $genpw, $protocol_version)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "%s"
string(0) ""
bool(true)
-===DONE===
test_bind($host, $port, "cn=userA,$base", "newPassword", $protocol_version)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump(ldap_errno($link));
var_dump(test_bind($host, $port, "cn=userA,$base", "newPassword", $protocol_version));
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_bind(): Unable to bind to server: Invalid credentials in %s on line %d
bool(false)
-===DONE===
ldap_exop_refresh($link, "cn=tmp,$base", 1234)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
?>
--EXPECT--
int(1234)
-===DONE===
ldap_exop_whoami($link)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
?>
--EXPECTF--
string(%d) "dn:%s"
-===DONE===
ldap_first_attribute($link, $entry)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
?>
--EXPECT--
string(11) "objectClass"
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECT--
ldap_first_attribute(): supplied resource is not a valid ldap result entry resource
-===DONE===
ldap_get_values($link, $entry, 'sn')
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
["count"]=>
int(1)
}
-===DONE===
ldap_parse_reference($link, $ref, $refs);
var_dump($refs);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
[0]=>
string(%d) "cn=userA,%s"
}
-===DONE===
$result = ldap_search($link, "$base", "(objectclass=person)");
var_dump(ldap_free_result($result));
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
?>
--EXPECT--
bool(true)
-===DONE===
ldap_get_attributes($link, $entry)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
["count"]=>
int(2)
}
-===DONE===
ldap_get_dn($link, $entry)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
?>
--EXPECTF--
string(%d) "%s"
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "o=test,%s"
}
}
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
["count"]=>
int(0)
}
-===DONE===
$option
);
?>
-===DONE===
--EXPECT--
bool(true)
int(3)
-===DONE===
ldap_get_option($link, LDAP_OPT_SERVER_CONTROLS, $controls_get)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
int(1)
bool(true)
bool(false)
-===DONE===
// This is a read-only option.
var_dump(ldap_set_option($link, LDAP_OPT_X_TLS_PACKAGE, 'foo'));
?>
-===DONE===
--EXPECT--
bool(true)
bool(false)
-===DONE===
$option
);
?>
-===DONE===
--EXPECT--
bool(true)
int(0)
string(5) "magic"
}
}
-===DONE===
ldap_get_values_len($link, $entry, "o")
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
["count"]=>
int(1)
}
-===DONE===
var_dump(ldap_get_values_len($link, $entry, "inexistentAttribute"));
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
--EXPECTF--
Warning: ldap_get_values_len(): Cannot get the value(s) of attribute %s in %s on line %d
bool(false)
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userB,%s"
}
}
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "o=test,%s"
}
}
-===DONE===
var_dump(ldap_mod_add($link, "dc=my-domain,$base", $entry2));
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_mod_add(): Modify: Undefined attribute type in %s on line %d
bool(false)
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
["count"]=>
int(0)
}
-===DONE===
// Invalid attributes
var_dump(ldap_mod_del($link, "$base", array('dc')));
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_mod_del(): Unknown attribute in the data in %s on line %d
bool(false)
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
["count"]=>
int(0)
}
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "cn=userA,%s"
}
}
-===DONE===
// Invalid attributes
var_dump(ldap_mod_replace($link, "$base", array('dc')));
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_mod_replace(): Unknown attribute in the data in %s on line %d
bool(false)
-===DONE===
)
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "o=test,%s"
}
}
-===DONE===
ldap_get_entries($link, ldap_search($link, "$base", "(sn=Brown-Smith)"))
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
string(%d) "cn=userA,%s"
}
}
-===DONE===
var_dump(ldap_modify_batch($link, "dc=my-domain,$base", $mods));
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_modify_batch(): Batch Modify: Undefined attribute type in %s on line %d
bool(false)
-===DONE===
var_dump(ldap_modify($link, "dc=my-domain,$base", $entry2));
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
Warning: ldap_modify(): Modify: Undefined attribute type in %s on line %d
bool(false)
-===DONE===
ldap_next_attribute($link, $entry)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "%s"
string(%d) "%s"
bool(false)
-===DONE===
ldap_next_attribute($link, $entry)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
--EXPECTF--
Warning: ldap_next_attribute(): called before calling ldap_first_attribute() or no attributes found in result entry in %s on line %d
bool(false)
-===DONE===
$entry = ldap_next_entry($link, $entry)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
int(1)
}
bool(false)
-===DONE===
ldap_parse_reference($link, $ref2, $refs);
var_dump($refs);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
[0]=>
string(%d) "cn=userB,%s"
}
-===DONE===
var_dump(@ldap_bind($link, $user, $passwd));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump(@ldap_bind($link, $user, $passwd));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
$refs
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
[0]=>
string(%d) "cn=userA,%s"
}
-===DONE===
$errcode, $dn, $errmsg, $refs
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
[0]=>
string(%d) "cn=userA,%s"
}
-===DONE===
ldap_get_entries($link, $result)['count']
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
int(%d)
string(%d) "%s"
int(1)
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "o=test,%s"
}
}
-===DONE===
$result = ldap_search($link, "$base", "(cn=userZ)", array("cn", "sn"));
var_dump(ldap_get_entries($link, $result));
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userZ,%s"
}
}
-===DONE===
ldap_count_entries($link, ldap_search($link, "$base", "(cn=userZ)", array("cn")))
);
?>
-===DONE===
--CLEAN--
<?php
require "connect.inc";
}
int(0)
int(1)
-===DONE===
ldap_set_option($link, LDAP_OPT_PROTOCOL_VERSION, $protocol_version);
var_dump(ldap_sasl_bind($link, null, $passwd, 'DIGEST-MD5', 'realm', $sasl_user));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
// Invalid DN syntax
var_dump(ldap_sasl_bind($link, "unexistingProperty=weirdValue,$user", $passwd));
?>
-===DONE===
--EXPECTF--
Warning: ldap_sasl_bind(): Unable to bind to server: Invalid DN syntax in %s on line %d
bool(false)
Warning: ldap_sasl_bind(): Unable to bind to server: Invalid DN syntax in %s on line %d
bool(false)
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userC,cn=userB,%s"
}
}
-===DONE===
$result = ldap_search(array($link, $link), $dn, array($filter), array('top'));
var_dump($result);
?>
-===DONE===
--EXPECTF--
Warning: ldap_search(): Search: No such object in %s on line %d
bool(false)
Warning: ldap_search(): Filter must either be a string, or an array with the same number of elements as the links array in %s on line %d
bool(false)
-===DONE===
$option
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
int(33)
bool(true)
int(44)
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userC,cn=userB,%s"
}
}
-===DONE===
bin2hex($controls[LDAP_CONTROL_VLVRESPONSE]['value']['context'])
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
int(3)
int(0)
string(%d) "%s"
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "o=test,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userC,cn=userB,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userA,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userA,%s"
}
}
-===DONE===
ldap_get_entries($link, $result)
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
string(%d) "cn=userA,%s"
}
}
-===DONE===
ldap_get_entries($link, $result[1])
);
?>
-===DONE===
--CLEAN--
<?php
include "connect.inc";
["count"]=>
int(0)
}
-===DONE===
ldap_get_option($link, LDAP_OPT_PROTOCOL_VERSION, $option);
var_dump($option);
?>
-===DONE===
--EXPECT--
bool(true)
int(3)
-===DONE===
var_dump($optionval);
}
?>
-===DONE===
--EXPECT--
bool(true)
string(8) "/foo/bar"
string(8) "/foo/bar"
bool(true)
string(8) "/foo/bar"
-===DONE===
ldap_get_option($link, LDAP_OPT_X_TLS_CIPHER_SUITE, $optionval);
var_dump($optionval);
?>
-===DONE===
--EXPECT--
bool(true)
string(4) "3DES"
-===DONE===
var_dump($optionval);
}
?>
-===DONE===
--EXPECT--
bool(true)
int(0)
int(1)
bool(true)
int(2)
-===DONE===
$result = ldap_set_option($link, LDAP_OPT_X_TLS_CRLCHECK, 9001);
var_dump($result);
?>
-===DONE===
--EXPECT--
bool(false)
-===DONE===
var_dump(ldap_set_option($link, 999999, 999999));
?>
-===DONE===
--EXPECTF--
bool(false)
Warning: ldap_set_option(): Expected array value for this option in %s on line %d
bool(false)
bool(false)
-===DONE===
var_dump($optionval);
}
?>
-===DONE===
--EXPECT--
bool(true)
int(5)
int(5)
bool(true)
int(5)
-===DONE===
var_dump($optionval);
}
?>
-===DONE===
--EXPECT--
bool(true)
int(0)
int(3)
bool(true)
int(4)
-===DONE===
$result = ldap_set_option($link, LDAP_OPT_X_TLS_REQUIRE_CERT, 9001);
var_dump($result);
?>
-===DONE===
--EXPECT--
bool(false)
-===DONE===
var_dump($optionval);
}
?>
-===DONE===
--EXPECT--
bool(true)
int(512)
int(770)
bool(true)
int(771)
-===DONE===
ldap_get_option($link, LDAP_OPT_MATCHED_DN, $option);
var_dump($option);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
}
bool(true)
string(14) "dc=test,dc=com"
-===DONE===
var_dump(ldap_set_rebind_proc($link, "rebind_proc"));
var_dump(ldap_set_rebind_proc($link, ""));
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
$link = ldap_connect($host, $port);
var_dump(ldap_set_rebind_proc($link, "rebind_proc_inexistent"));
?>
-===DONE===
--EXPECTF--
Warning: ldap_set_rebind_proc(): Two arguments expected for 'rebind_proc_inexistent' to be a valid callback in %s on line %d
bool(false)
-===DONE===
ldap_set_option($link, LDAP_OPT_PROTOCOL_VERSION, $protocol_version);
var_dump(ldap_start_tls($link));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump(ldap_unbind($link));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump(ldap_unbind($link));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
bin2hex(mb_convert_encoding("\x81\x8d\x8f\x90\x9d", 'UTF-8', 'Windows-1252'))
);
?>
-===DONE===
--EXPECT--
string(6) "efbfbd"
string(30) "efbfbdefbfbdefbfbdefbfbdefbfbd"
-===DONE===
mb_substr('bar', 0x100000000, 1)
);
?>
-==DONE==
--EXPECT--
string(3) "bar"
string(3) "bar"
string(0) ""
string(0) ""
-==DONE==
var_dump(mb_detect_order('Foo, UTF-8'));
var_dump(mb_detect_order(['Foo', 'UTF-8']))
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
-===DONE===
<?php mb_parse_str("test=&@AB€‚äöü€⟨⟩", $test);
print_r($test);
?>
-===DONE===
--EXPECT--
HTML-ENTITIES>UTF-8>HTML-ENTITIES
Array
(
[test] => &@AB€‚äöü€⟨⟩
)
-===DONE===
var_dump(bin2hex($b));
?>
-===DONE===
--EXPECT--
*** Testing mb_decode_mimeheader() : basic functionality ***
string(60) "e697a5e69cace8aa9ee38386e382ade382b9e38388e381a7e38199e38082"
string(60) "e697a5e69cace8aa9ee38386e382ade382b9e38388e381a7e38199e38082"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing mb_decode_mimeheader() : variation ***
string(106) "e697a5e69cace8aa9ee38386e382ade382b9e38388e381a7e38199e380823031323334efbc95efbc96efbc97efbc98efbc99e38082"
string(106) "e697a5e69cace8aa9ee38386e382ade382b9e38388e381a7e38199e380823031323334efbc95efbc96efbc97efbc98efbc99e38082"
string(106) "e697a5e69cace8aa9ee38386e382ade382b9e38388e381a7e38199e380823031323334efbc95efbc96efbc97efbc98efbc99e38082"
string(106) "e697a5e69cace8aa9ee38386e382ade382b9e38388e381a7e38199e380823031323334efbc95efbc96efbc97efbc98efbc99e38082"
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing mb_decode_mimeheader() : variation ***
string(48) "e1e2e3e4e5e6e7e8e9eaebecedeeeff0f1f3f4f5f6f7f8f9"
-===DONE===
var_dump($args);
}
?>
-===DONE===
--EXPECTF--
bool(false)
array(3) {
array(0) {
}
}
-===DONE===
var_dump(mb_ereg_search_getpos());
}
?>
-==DONE==
--EXPECTF--
bool(true)
Warning: mb_ereg_search_setpos(): Position is out of range in %s on line %d
bool(false)
int(0)
-==DONE==
echo ini_get('mbstring.internal_encoding')."\n";
?>
-===DONE===
--EXPECT--
*** Testing INI mbstring.internal_encoding : basic functionality ***
ISO-8859-7
ISO-8859-7
UTF-8
ISO-8859-7
-===DONE===
echo mb_strcut('foobarbaz', 6, null, 'UTF-8') . "\n";
echo mb_strimwidth('foobar', 0, 3, null, 'UTF-8') . "\n";
?>
-==DONE==
--EXPECT--
1
2
baz
baz
foo
-==DONE==
($r === FALSE) ? print "OK_NEWLINE\n" : print "NG_NEWLINE\n";
?>
-==DONE==
--EXPECTF--
String len: 43
== POSITIVE OFFSET ==
0
OK_STR
OK_NEWLINE
-==DONE==
var_dump(mb_stristr($string_mb, $needle2));
?>
-===DONE===
--EXPECT--
*** Testing mb_stristr() : basic functionality ***
-- Multibyte string: needle doesn't exist --
bool(false)
-===DONE===
var_dump( mb_stristr($haystack, $needle, $part, $encoding) );
?>
-===DONE===
--EXPECTF--
*** Testing mb_stristr() : error conditions ***
Warning: mb_stristr(): Unknown encoding "unknown-encoding" in %s on line %d
bool(false)
-===DONE===
var_dump(bin2hex(mb_stristr($string_mb, $needle_mb_mixed, true)));
?>
-===DONE===
--EXPECT--
*** Testing mb_stristr() : basic functionality ***
string(8) "cebacebb"
string(54) "cebccebdcebece9fcea0cea120cebacebbce9cce9dcebecebfcea0"
string(8) "cebacebb"
-===DONE===
($r === FALSE) ? print "OK_NEWLINE\n" : print "NG_NEWLINE\n";
?>
-==DONE==
--EXPECTF--
String len: 43
== POSITIVE OFFSET ==
0
OK_STR
OK_NEWLINE
-==DONE==
var_dump(mb_strrchr($string_mb, $needle2));
?>
-===DONE===
--EXPECT--
*** Testing mb_strrchr() : basic functionality ***
-- Multibyte string: needle doesn't exist --
bool(false)
-===DONE===
var_dump( mb_strrchr($haystack, $needle, $part, $encoding) );
?>
-===DONE===
--EXPECTF--
*** Testing mb_strrchr() : error conditions ***
Warning: mb_strrchr(): Unknown encoding "unknown-encoding" in %s on line %d
bool(false)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing mb_strrchr() : variation ***
-- Ascii data --
-- mb data in utf-8 --
string(30) "e8aa9ee38386e382ade382b9e38388"
string(70) "e697a5e69cace8aa9ee38386e382ade382b9e383883334efbc95efbc96e697a5e69cac"
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing mb_strrchr() : variation ***
-- Ascii data --
string(52) "cebccebdcebecebfcf80cf81cf83cf84cf85cf86cf87cf88cf89"
bool(false)
bool(false)
-===DONE===
var_dump(mb_strrichr($string_mb, $needle2));
?>
-===DONE===
--EXPECT--
*** Testing mb_strrichr() : basic functionality ***
-- Multibyte string: needle doesn't exist --
bool(false)
-===DONE===
var_dump( mb_strrichr($haystack, $needle, $part, $encoding) );
?>
-===DONE===
--EXPECTF--
*** Testing mb_strrichr() : error conditions ***
Warning: mb_strrichr(): Unknown encoding "unknown-encoding" in %s on line %d
bool(false)
-===DONE===
var_dump(bin2hex(mb_strrichr($string_mb, $needle_mb_mixed, true)));
?>
-===DONE===
--EXPECT--
*** Testing mb_strrichr() : basic functionality ***
string(42) "cebacebbcebccebdcebece9fcea0cea120cebacebb"
string(20) "ce9cce9dcebecebfcea0"
string(42) "cebacebbcebccebdcebece9fcea0cea120cebacebb"
-===DONE===
var_dump(mb_strstr($string_mb, $needle2));
?>
-===DONE===
--EXPECT--
*** Testing mb_strstr() : basic functionality ***
-- Multibyte string: needle doesn't exist --
bool(false)
-===DONE===
var_dump( mb_strstr($haystack, $needle, $part, $encoding) );
?>
-===DONE===
--EXPECTF--
*** Testing mb_strstr() : error conditions ***
Warning: mb_strstr(): Unknown encoding "unknown-encoding" in %s on line %d
bool(false)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing mb_strstr() : variation ***
-- Ascii data --
-- mb data in utf-8 --
string(88) "e8aa9ee38386e382ade382b9e383883334efbc95efbc96e697a5e69cace8aa9ee38386e382ade382b9e38388"
string(12) "e697a5e69cac"
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing mb_strstr() : variation ***
-- Ascii data --
string(52) "cebccebdcebecebfcf80cf81cf83cf84cf85cf86cf87cf88cf89"
bool(false)
bool(false)
-===DONE===
var_dump( mb_strtolower($sourcestring, $encoding) );
?>
-===DONE===
--EXPECTF--
*** Testing mb_strtolower() : error conditions***
Warning: mb_strtolower(): Unknown encoding "unknown-encoding" in %s on line %d
bool(false)
-===DONE===
var_dump( mb_substitute_character("b") );
?>
-===DONE===
--EXPECTF--
*** Testing mb_substitute_character() : basic functionality ***
int(63)
Warning: mb_substitute_character(): Unknown character in %s on line %d
bool(false)
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECTF--
*** Testing mb_substitute_character() : usage variation ***
--unset var--
Error: 2 - mb_substitute_character(): Unknown character, %s(%d)
bool(false)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing mb_substitute_character() : variation ***
string(14) "3f3f3f3f3f3f3f"
string(14) "42424242424242"
string(0) ""
string(14) "3f3f3f3f3f3f3f"
-===DONE===
mysqli_close($con);
?>
-==DONE==
--EXPECT--
int(1)
-==DONE==
mysqli_close($link);
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
}
?>
-==DONE==
--EXPECT--
string(1) "0"
string(4) "1365"
-==DONE==
var_dump($rm->getNumberOfParameters());
var_dump($rm->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(2)
int(1)
int(1)
int(0)
-===DONE===
\r
$link->close();\r
?>\r
-=== DONE ===\r
--CLEAN--\r
<?php\r
require_once("clean_table.inc");\r
["type"]=>\r
int(1)\r
}\r
-=== DONE ===\r
?>
===DONE===
-<?php exit(0); ?>
--EXPECT--
===DONE===
?>
===DONE===
-<?php exit(0); ?>
--EXPECT--
===DONE===
?>
===DONE===
-<?php exit(0); ?>
--EXPECT--
===DONE===
var_dump($b1, $b2);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
bool(true)
bool(false)
bool(false)
bool(true)
-===DONE===
@oci_execute($statement);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
bool(true)
Test 6
NULL
NULL
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
TEST86 insert all ORATYPE values
string(9) "09-APR-10"
}
}
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 insert numbers
array(0) {
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - invalid number
string(2) "42"
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(1) {
string(6) "MILLER"
Test 3
string(4) "FORD"
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 0 - base table creation without binds
array(5) {
NULL
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
TEST241 bind SQLT_CHR
array(1) {
NULL
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - PL/SQL IN and OUT variables
string(22) "Cat got your keyboard?"
string(22) "CAT GOT YOUR KEYBOARD?"
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
TEST141 wrong bind type SQLT_INT
array(1) {
TEST159
int(5555)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - baseline test
array(2) {
array(0) {
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - baseline test
array(2) {
array(0) {
}
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test - SQLT_AVC
Test - SQLT_ODT
Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 156 in %sbind_unsupported_1.php on line %d
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test - SQLT_BDOUBLE
Test - SQLT_BFLOAT
Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 21 in %sbind_unsupported_2.php on line %d
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test - SQLT_CLOB
Test - OCI_B_BLOB
Warning: oci_bind_by_name(): Unable to find descriptor property in %sbind_unsupported_3.php on line %d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
COL4
Test 2
Warning: oci_fetch_array(): ORA-%r(24338|01002)%r: %sbug36403.php on line %d
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(1) {
}
string(1) "X"
string(1) "X"
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
string(26) "This should be the output."
string(26) "This should be the output."
Test 4
string(26) "This should be the output."
-===DONE===
var_dump($rs1);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
array(1) {
Warning: oci_fetch_all(): ORA-01002: %s in %s on line %d
array(0) {
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
ORA-20000: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaBcccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccDeeeeeeeeeeee
Test 2
oci_execute(): ORA-20000: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaBcccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccDeeeeeeeeeeee
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
ORA-57000: TT8507: ORA-20000: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
Test 2
oci_execute(): ORA-57000: TT8507: ORA-20000: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - Parse
array(4) {
["sqltext"]=>
string(30) "select reallynothere from dual"
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - Execute - after successful 2nd query with same statement
bool(false)
bool(false)
bool(false)
bool(false)
-===DONE===
$stmtarray = array("DROP TABLE BUG68298");
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(1) {
["COL1"]=>
string(20) "-1152921504606846975"
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1: Bind input parameter in a local function
array(2) {
string(4) "STR1"
string(4) "STR2"
string(9) "STR1 STR2"
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(1) {
["RAW_QUERY"]=>
["STRING_BIND_PARAMETER"]=>
string(3) "Foo"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
Executing SELECT statament...
2 Records Found
0|1|9
1|11|19
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - P1 Value: NULL P1 Length: Default P1 Type: Default P2 Value: NULL P2 Length: Default P2 Type: Default
bool(true)
Warning: oci_execute(): ORA-24816: %s in %s on line %d
bool(false)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(5) {
[0]=>
[4]=>
int(-10)
}
-===DONE===
$r = mysleep($c, 8); // seconds
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
Execute error was ORA-03136: %s
-===DONE===
echo oci_client_version(), "\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
%d.%d.%d.%d.%d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
First Insert
Could not execute: ORA-02290: %s (%s.COMMIT_002_TAB_CHECK_X) %s
ORA-02290: %s (%s.COMMIT_002_TAB_CHECK_Y) %s in %scommit_002.php on line %d
Could not commit: ORA-02091: %s
ORA-02290: %s (%s.COMMIT_002_TAB_CHECK_Y) %s
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and %s are set and point to the right directories in %s on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and %s are set and point to the right directories in %s on line %d
Warning: oci_connect(): Error while trying to retrieve text for error ORA-01804
in %s on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Warning: ocilogon(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and %s are set and point to the right directories in %s on line %d
Warning: ocilogon(): %s ORA-01804
in %s on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Warning: ocilogon(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and %s are set and point to the right directories in %s on line %d
Warning: ocilogon(): Error while trying to retrieve text for error ORA-01804
in %sconnect_without_oracle_home_old_11.php on line %d
bool(false)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(2) {
[0]=>
string(1) "1"
}
bool(false)
-===DONE===
dq($c, 'select dbop_name from v$sql_monitor where dbop_name is not null order by dbop_exec_id desc');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(1) {
["DBOP_NAME"]=>
string(7) "db_op_1"
}
-===DONE===
dq($c, 'select sql_text, dbop_name from v$sql_monitor where sql_text like \'%dboptest%\' order by dbop_exec_id desc');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(1) {
["DBOP_NAME"]=>
NULL
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(1) {
[99]=>
string(53) "99 test 4 Hello, world! Lots and lots and ... of text"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
string(%d) "some"
Test 2
string(%d) "some"
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - define last
NULL
Test 6 - fetch on wrong handle
Warning: oci_fetch_row(): ORA-24374: %s in %sdefine6.php on line %d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - OCI_ASSOC
array(3) {
[3]=>
string(5) "jones"
}
-===DONE===
oci_execute($s);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
Warning: oci_execute(): ORA-20333: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBab in %serror3.php on line %d
-===DONE===
var_dump($r);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
bool(false)
bool(true)
bool(true)
bool(true)
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
string(0) ""
}
bool(false)
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
string(0) ""
}
bool(false)
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
string(0) ""
}
bool(false)
-===DONE===
var_dump($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
Warning: oci_pconnect(): External Authentication is not supported on Windows in %s on line %d
bool(false)
bool(false)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
int(0)
}
Test 2
bool(false)
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
int(3)
int(0)
array(0) {
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
object(stdClass)#1 (3) {
Notice: Undefined property: stdClass::$CASESENSITIVE in %sfetch_object.php on line %d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
object(stdClass)#%d (3) {
Notice: Undefined property: stdClass::$CASESENSITIVE in %sfetch_object_1.php on line %d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
object(stdClass)#%d (3) {
789
3rd row col2 string
3 more text
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
array(4) {
[0]=>
int(0)
int(0)
int(7)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 - oci_fetch_assoc
array(2) {
["C2"]=>
string(5) "klmno"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
Test 2
[0]=>
string(1) "X"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1 a 1 a 1 a 1 a 1 a
v
w
X
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
[0]=>
string(1) "2"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
[0]=>
string(1) "2"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
array(2) {
["C2"]=>
string(1) "f"
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1
273
274
275
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
ORA-06512: at "SYS.DBMS_SQL", line %d
ORA-06512: at "SYS.DBMS_SQL", line %d
ORA-06512: at "%s.IMP_RES_CALL_ERR_PROC", line %d in %simp_res_call_error.php on line %d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1
bool(true)
3
bool(true)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
1
Warning: oci_fetch_array(): supplied resource is not a valid oci8 statement resource in %simp_res_close.php on line %d
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
X
t
u
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(2) {
[1]=>
string(18) "dbms_output Line 2"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - can't get IRS fields from parent
num fields : 0
}
num fields : 1
C4_NUMBER52 : is_null T, precision 5, scale 2, size 22, typeraw 2, type NUMBER
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
ORA-06512: %s
ORA-06512: %s
ORA-06512: %s
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1 abcde
t
u
X
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1 abcde
t
u
X
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1 abcde
t
u
X
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
1 abcde
Warning: oci_fetch_array(): ORA-01002: %s in %simp_res_get_4.php on line %d
Return is false
-===DONE===
oci_free_statement($s);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
3
Test 4 - skip IRSs
5
6
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(1) {
string(1) "6"
}
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1
3
-===DONE===
oci_free_statement($s);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
1
5
Warning: oci_fetch_array(): supplied resource is not a valid oci8 statement resource in %s on line %d
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
1
Warning: oci_fetch_array(): OCI_INVALID_HANDLE in %s on line %d
Warning: oci_get_implicit_resultset(): supplied resource is not a valid oci8 statement resource in %s on line %d
-===DONE===
oci_free_statement($s);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1
4
5
6
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1 abcde
t
u
X
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
array(3) {
[2]=>
string(6) "Line 3"
}
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1
2
-===DONE===
var_dump($s1);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
bool(false)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - No commit in procedure, OCI_COMMIT_ON_SUCCESS mode
111
[3]=>
string(3) "444"
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
1 aaaaa a
Test 2 - don't fetch all rows
1 aaaaa a
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - prefetch 0
bool(true)
[0]=>
string(1) "v"
}
-===DONE===
echo 'oci8.old_oci_close_semantics = ' . ini_get('oci8.old_oci_close_semantics') . "\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - check initialization
oci8.privileged_connect = 1
oci8.default_prefetch = 555
bool(false)
oci8.old_oci_close_semantics = 1
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(OCI-Lob)#%d (1) {
["descriptor"]=>
NULL
bool(false)
int(40004)
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
string(4) "data"
string(4) "data"
Test 3 - bind with SQLT_CLOB (an alias for OCI_B_CLOB)
string(10) "more stuff"
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1
f1 ended
Test 2
f2 ended
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Test 1 - truncate on insert
int(72)
Test 2 - read it back
string(0) ""
-===DONE===
var_dump($res);
?>
-===DONE===
--EXPECT--
bool(true)
array(1) {
string(4) "test"
}
}
-===DONE===
var_dump($r);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1: Import
Warning: OCI-Lob::export() expects parameter 1 to be a valid path, string given in %snull_byte_1.php on line %d
NULL
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1: Valid use of a null byte
array(1) {
Warning: oci_bind_by_name(): ORA-01036: %s in %snull_byte_2.php on line %d
Warning: oci_execute(): ORA-01008: %s in %snull_byte_2.php on line %d
-===DONE===
var_dump($res);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1: Invalid use of a null byte
array(0) {
}
}
-===DONE===
oci_connect('abc', 'def', 'ghi', 'jkl');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and %s are set and point to the right directories in %s on line %d
Warning: oci_connect(): Error while trying to retrieve text for error ORA-01804
in %specl_bug16035.php on line %d
-===DONE===
oci_close($c);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1
Raises NO_DATA_FOUND
["sqltext"]=>
string(29) "begin raise ZERO_DIVIDE; end;"
}
-===DONE===
reflection::export(new reflectionfunction('oci_get_implicit_resultset'));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Function [ <internal%s> function oci_define_by_name ] {
}
}
-===DONE===
reflection::export(new reflectionclass('OCI-Collection'));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Class [ <internal:oci8> class OCI-Lob ] {
}
}
-===DONE===
oci8_test_sql_execute($c, $stmtarray);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Test 1 Insert new XML data using a temporary CLOB
array(1) {
%sVClearance>10</VClearance>
</Warehouse>
"
-===DONE===
odbc_close($link);
?>
-==DONE==
--EXPECT--
array(3) {
["PAR_ID"]=>
["PAR_CHR"]=>
string(6) "test 7"
}
-==DONE==
--CLEAN--
<?php
include 'config.inc';
}
}
?>
-==DONE==
--EXPECT--
100
a
a
-==DONE==
--CLEAN--
<?php
include 'config.inc';
odbc_close($conn);
?>
-==DONE==
--EXPECT--
array(1) {
["ID"]=>
string(1) "1"
}
-==DONE==
--CLEAN--
<?php
include 'config.inc';
odbc_close($conn);
?>
-==DONE==
--EXPECTF--
string(42) "/* non existent procedure xy */ execute xy"
string(5) "37000"
string(5) "S0002"
string(%d) "[Microsoft][%s][SQL Server]Invalid object name 'zwiebelfleisch'."
-==DONE==
var_dump($r);
?>
-==DONE==
--EXPECT--
array(3) {
["i"]=>
["k"]=>
string(2) "34"
}
-==DONE==
--CLEAN--
<?php
include 'config.inc';
$g = new G;
?>
-===DONE===
--EXPECTF--
Warning: Can't preload unlinked class H: Unknown type dependencies in %s on line %d
Warning: Can't preload unlinked class B: Unknown type dependencies in %s on line %d
Warning: Can't preload unlinked class A: Unknown type dependencies in %s on line %d
-===DONE===
--SKIPIF--
<?php require_once('skipif.inc'); ?>
--FILE--
-===DONE===
--EXPECTF--
Warning: Can't preload class Test with unresolved initializer for constant C in %s on line %d
-===DONE===
$var0 = array(0 => "hello", 1 => "world");
$var2 = openssl_csr_new(array(0),$var0,null,array(0));
?>
-==DONE==
--EXPECTF--
Warning: openssl_csr_new(): dn: numeric fild names are not supported in %sbug72165.php on line %d
Warning: openssl_csr_new(): add1_attr_by_txt challengePassword_min -> 4 (failed; check error queue and value of string_mask OpenSSL option if illegal characters are reported) in %sbug72165.php on line %d
-==DONE==
var_dump(openssl_pkcs12_read($cert_store, $cert_info, "csos"));
var_dump(openssl_error_string());
?>
-===DONE===
--EXPECT--
bool(true)
bool(false)
-===DONE===
test($p12, 'qwerty');
?>
-===DONE===
--EXPECT--
int(2)
-===DONE===
unlink($tmpFileOut2);
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
int(39)
int(39)
int(39)
-==DONE==
unlink($outPath);
?>
-==DONE==
--EXPECT--
bool(true)
-==DONE==
unlink($tmpFileOut2);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
int(40)
string(80) "537472696e672077697468200a2077696c6c20656e6420696e206f6e652062797465206d6f72652e"
string(80) "537472696e672077697468200a2077696c6c20656e6420696e206f6e652062797465206d6f72652e"
-===DONE===
unlink($tmpFileOut);
?>
-==DONE==
--EXPECT--
bool(true)
bool(true)
-==DONE==
var_dump($rf->getNumberOfParameters());
var_dump($rf->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(6)
int(4)
-===DONE===
<?php
preg_match("/\9a(?:F?+(?:^(?(R)a+\"){99}-))(?J)(?'R'(?'R'<((?'RR'(?'R'\){97)?J)?J)(?'R'(?'R'\){99|(:(?|(?'R')(\k'R')|((?'R')))H'R'R)(H'R))))))/", "*b\dc");
?>
-==DONE==
--EXPECTF--
Warning: preg_match(): Compilation failed: unmatched closing parenthesis at offset %d in %s on line %d
-==DONE==
<?php
var_dump(preg_match('/\w/u', 'ä'));
?>
-===DONE===
--EXPECT--
int(1)
-===DONE===
var_dump(preg_match('/./', "a"));
?>
-==DONE==
--EXPECT--
int(1)
-==DONE==
);
echo '3', "\n";
?>
-===DONE===
--EXPECT--
123
-===DONE===
preg_last_error()
);
?>
-===DONE===
--EXPECT--
int(1)
int(0)
-===DONE===
var_dump(preg_match('~(*NO_JIT)(a)*~', str_repeat('a', 5431), $match))
?>
-==DONE==
--EXPECT--
int(1)
int(1)
-==DONE==
echo "PREG_BAD_UTF8_ERROR= ", PREG_BAD_UTF8_ERROR, "\n";
?>
-===Done===
--EXPECT--
PCRE constants test
PREG_PATTERN_ORDER= 1
PREG_BACKTRACK_LIMIT_ERROR= 2
PREG_RECURSION_LIMIT_ERROR= 3
PREG_BAD_UTF8_ERROR= 4
-===Done===
var_dump(preg_filter($pattern, $replace, $subject));
?>
-===DONE===
--EXPECT--
array(6) {
[0]=>
[7]=>
string(3) "A:4"
}
-===DONE===
var_dump($matches);
?>
-===Done===
--EXPECT--
array(2) {
[0]=>
[1]=>
string(1) "y"
}
-===Done===
var_dump("Done, $count matches.");
}
?>
-==DONE==
--EXPECT--
string(16) "Done, 1 matches."
-==DONE==
preg_match('/[\-\+]?[0-9\.]*/', $string, $string);
var_dump($string);
?>
-===Done===
--EXPECT--
array(1) {
[0]=>
string(2) "-1"
}
-===Done===
var_dump(preg_replace(array('/[\w]+/'), array('$'), array('xyz', 'bdbd')));
var_dump(preg_replace(array('/\s+/', '~[b-d]~'), array('$'), array('x y', 'bd bc')));
-echo "==done==\n";
-
?>
--EXPECT--
string(1) "c"
[1]=>
string(1) "$"
}
-==done==
var_dump(preg_replace_callback($regex_value, 'integer_word', $subject));
}
?>
-===Done===
--EXPECTF--
*** Testing preg_replace_callback() : error conditions ***
Arg value is /[0-9]/
string(11) "number one."
-===Done===
var_dump($res->fetchAll(PDO::FETCH_CLASS|PDO::FETCH_PROPS_LATE, 'SimpleXMLElement', array('<root/>')));
?>
-===DONE===
--EXPECTF--
array(1) {
[0]=>
string(3) "xyz"
}
}
-===DONE===
var_dump($db->query("SELECT * FROM test")->fetchAll(PDO::FETCH_ASSOC));
?>
-===DONE===
--EXPECT--
array(2) {
[0]=>
string(2) "11"
}
}
-===DONE===
var_dump($db->query("SELECT * FROM test")->fetchAll(PDO::FETCH_ASSOC));
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(1) "1"
}
}
-===DONE===
var_dump($res->fetchAll(PDO::FETCH_FUNC, function($a) { return strtoupper($a); }));
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(3) "XYZ"
}
-===DONE===
$db->exec("DROP TABLE test");
?>
-===DONE===
--EXPECT--
Calling object method 'foo'
Calling object method 'bar'
Calling object method 'lucky'
-===DONE===
!isset($row->missing)
);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
bool(true)
bool(true)
bool(true)
-===DONE===
$db->exec("DROP TABLE test");
?>
-===DONE===
--EXPECTF--
===FAIL===
[2]=>
NULL
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
bool(true)
-===DONE===
}
?>
-==DONE==
--EXPECT--
string(1) "1"
string(1) "3"
string(2) "12"
-==DONE==
pg_close($db);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (pgsql link%s)
-===DONE===
pg_close($dbh);
?>
-===DONE===
--EXPECT--
Array
(
(
[id] => 3
)
-===DONE===
pg_close($dbh);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (pgsql result)
resource(%d) of type (pgsql result)
string(1) "f"
}
string(14) "NOTICE: 11111"
-===DONE===
pg_close(dbh);
?>
-===DONE===
--EXPECTF--
resource(%d) of type (pgsql result)
array(1) {
string(1) "f"
}
string(14) "NOTICE: 11111"
-===DONE===
@unlink($tracefile);
?>
-===DONE===
--CLEAN--
<?php
resource(%d) of type (pgsql result)
bool(true)
bool(true)
-===DONE===
pg_query($dbh, "DROP TABLE php_test");
pg_close($dbh);
?>
-===DONE===
--EXPECTF--
array(2) {
["id"]=>
["time"]=>
string(%d) "%s"
}
-===DONE===
pg_close($db);
?>
-==DONE==
--EXPECT--
array(2) {
[0]=>
string(19) "2001:4f8:3:ba::/112"
}
7 errors catched
-==DONE==
pg_query("DROP TABLE $table");
?>
-==DONE==
--EXPECT--
array(2) {
["value"]=>
["details"]=>
string(37) "insert after looping with a reference"
}
-==DONE==
pg_query($conn, "ROLLBACK");
pg_close($conn);
?>
-==DONE==
--EXPECTF--
pg_lo_create(): supplied resource is not a valid PostgreSQL link resource%w
int(%d)
int(%d)
-==DONE==
}
?>
-==DONE==
--EXPECT--
string(1) "1"
string(1) "2"
string(1) "3"
-==DONE==
<?php
var_dump(Phar::apiVersion());
?>
-===DONE===
--EXPECT--
string(5) "1.1.1"
-===DONE===
var_dump(Phar::canCompress(Phar::GZ) == extension_loaded("zlib"));
var_dump(Phar::canCompress(Phar::BZ2) == extension_loaded("bz2"));
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
var_dump(file_get_contents($pname . '/b/c.php'));
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
string(28) "<?php echo "This is a\n"; ?>"
string(28) "<?php echo "This is b\n"; ?>"
string(30) "<?php echo "This is b/c\n"; ?>"
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php unlink(dirname(__FILE__) . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
This is a
This is b
This is b/c
-===DONE===
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
This is a
This is b
This is b/c
-===DONE===
include $pname . '/b/b';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
This is a
This is b
This is b/b
-===DONE===
require $pname . '/a.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
This is b/c
This is b/d
This is e
-===DONE===
var_dump(opendir("phar://"));
var_dump(opendir("phar://foo.phar/hi"));
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: opendir(phar://foo.phar/hi): failed to open dir: phar error: invalid url or non-existent phar "phar://foo.phar/hi"
phar url "phar://foo.phar/hi" is unknown in %s027.php on line %d
bool(false)
-===DONE===
include $pname . '/a.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
This is b/c
This is b/d
This is e
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.1.phar.php');
bool(true)
bool(true)
alias "copy" is already used for archive "%s029.1.phar.php" cannot be overloaded with "%s029.2.phar.php"
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
This is e
bool(false)
Cannot directly get any files or directories in magic ".phar" directory
-===DONE===
$a['dir']->chmod(0666);
var_dump($a['dir']->isReadable());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.1.phar.php');
bool(true)
bool(false)
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.1.phar.php');
--EXPECTF--
bool(false)
Cannot modify permissions for file "a.php" in phar "%s033a.1.phar.php", write operations are prohibited
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
phar error: unable to open file "%s/does/not/exist" to add to phar archive
Cannot create any files in magic ".phar" directory
Cannot create any files in magic ".phar" directory
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
2
Cannot open archive "%salias_acrobatics.2.phar", alias is already in use by existing archive
alias "another" is already used for archive "%salias_acrobatics.phar" cannot be overloaded with "%salias_acrobatics.phar"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
Phar::mungServer() expects parameter 1 to be array, string given
Phar::createDefaultStub() expects parameter 1 to be a valid path, array given
Write operations disabled by the php.ini setting phar.readonly
Phar::setMetadata() expects exactly 1 parameter, 2 given
Write operations disabled by the php.ini setting phar.readonly
-===DONE===
}
echo("\n Written Files($i)\n");
?>
-===DONE===
--CLEAN--
<?php
$dirName = __DIR__;
4095
Written Files(4096)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
string(26) "file 0 in DataArchive.phar"
unable to seek to start of file "0" while creating new phar "%sDataArchive.phar"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
["f2999"]=>
string(22) "*bug45218_SLOWTEST.txt"
}
-===DONE===
var_dump($phar['blah']->isDir(), $phar['test']->isDir());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar');
--EXPECT--
bool(true)
bool(false)
-===DONE===
rename("phar://a.phar/x", "phar://a.phar/y");
var_dump(rename("phar://a.phar/x", "phar://a.phar/y"));
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');?>
--EXPECTF--
Warning: rename(): phar error: cannot rename "phar://a.phar/x" to "phar://a.phar/y" from extracted phar archive, source does not exist in %sbug47085.php on line %d
bool(false)
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.zip');?>
--EXPECTF--
data phar "%sbug48377.2.phar.zip" has invalid extension phar.zip
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.zip');?>
--EXPECTF--
phar "%sbug48377.zip" exists and must be unlinked prior to conversion
-===DONE===
var_dump($item->getFileName());
}
?>
-===DONE===
--EXPECT--
string(5) "a.php"
string(5) "b.php"
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__."/bug64931.phar");
CAUGHT: Cannot create any files in magic ".phar" directory
CAUGHT: Cannot create any files in magic ".phar" directory
CAUGHT: Phar::addFromString() expects parameter 1 to be a valid path, string given
-===DONE===
}
?>
-==DONE==
--EXPECTF--
UnexpectedValueException: phar error: corrupted central directory entry, no magic signature in zip-based phar "%sbug69441.phar" in %sbug69441.php:%d
Stack trace:
#0 %s%ebug69441.php(%d): Phar->__construct('%s', 0)
#1 {main}
-==DONE==
}
?>
-==DONE==
--EXPECTF--
UnexpectedValueException: phar error: "%s%ebug69453.tar.phar" is a corrupted tar file (checksum mismatch of file "") in %s:%d
Stack trace:
#0 %s%ebug69453.php(%d): Phar->__construct('%s', 0)
#1 {main}
-==DONE==
$phar->extractTo($dir);
var_dump(file_exists("$dir/ThisIsATestFile.txt"));
?>
-===DONE===
--CLEAN--
<?php
$dir = __DIR__."/bug70019";
?>
--EXPECT--
bool(true)
-===DONE===
var_dump($r->getNumberOfRequiredParameters());
var_dump($r->getNumberOfParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(3)
int(1)
int(4)
-===DONE===
Phar::mount('phar://' . __DIR__ . '/files/write4.phar/testit.txt', 'phar://' . __DIR__ . '/files/write4.phar/tobemounted');
var_dump(file_exists('phar://' . __DIR__ . '/files/write4.phar/testit.txt'), file_get_contents('phar://' . __DIR__ . '/files/write4.phar/testit.txt'));
?>
-===DONE===
--EXPECT--
bool(false)
bool(true)
string(2) "hi"
-===DONE===
var_dump(is_dir($pname . '/d'));
var_dump(is_dir($pname . '/b/c.php'));
?>
-===DONE===
--EXPECTF--
string(131) "<?php echo "in b\n";$a = fopen("index.php", "r", true);echo stream_get_contents($a);fclose($a);include dirname(__FILE__) . "/../d";"
string(1) "b"
bool(true)
bool(false)
bool(false)
-===DONE===
include $pname . '/b.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
bool(true)
modified!
another!
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.php/$fileName.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
brand new!
Text in utf8 file.
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.php/a.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%screate_new_phar_b.phar.php/a.php' for inclusion (include_path='%s') in %screate_new_phar_b.php on line %d
-===DONE===
var_dump($phar->getSignature());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
["hash_type"]=>
string(5) "SHA-1"
}
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
12:Error: file_put_contents(phar://%s): failed to open stream: phar error: invalid path "%s" contains illegal character
13:Error: file_put_contents(phar://%s): failed to open stream: phar error: invalid path "%s" contains illegal character
Exception: Phar::offsetSet() expects parameter 1 to be a valid path, string given
-===DONE===
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sdelete_in_phar.phar.php/b/c.php' for inclusion (include_path='%s') in %sdelete_in_phar.php on line %d
-===DONE===
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
This is b
This is b/c
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.php/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sdelete_in_phar_confirm.phar.php/b/c.php' for inclusion (include_path='%s') in %sdelete_in_phar_confirm.php on line %d
-===DONE===
rmdir($pname . '/');
mkdir($pname . '/');
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/ok.phar'); ?>
Warning: rmdir(): phar error: cannot remove directory "" in phar "%sdir.phar.php", directory does not exist in %sdir.php on line %d
Warning: mkdir(): phar error: cannot create directory "" in phar "%sdir.phar.php", phar error: invalid path "" must not be empty in %sdir.php on line %d
-===DONE===
include $pname . '/foo/hi';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php rmdir(__DIR__ . '/poo'); ?>
echo file_get_contents("./hi");
echo file_get_contents("./hi", 0, $context, 0, 0);
?>
-===DONE===
__HALT_COMPILER();');
include $fname;
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
hihi
Warning: fopen(notfound.txt): failed to open stream: No such file or directory in phar://%sfopen.phar.php/index.php on line %d
-===DONE===
include $pname . '/test.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.phar.php'); ?>
Warning: fopen(./notfound.php): failed to open stream: No such file or directory in phar://%sfopen_edgecases.phar.php/test.php on line %d
-===DONE===
');
include $pname . '/foo/hi';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php rmdir(__DIR__ . '/poo'); ?>
test
Warning: fopen(phar://%sfopen_edgecases2.phar.php/oops): failed to open stream: phar error: path "oops" is a directory in phar://%sfopen_edgecases2.phar.php/foo/hi on line %d
-===DONE===
include 'file1.php';
include 'file2.php';
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tempmanifest1.phar.php');
Warning: include(file2.php): failed to open stream: No such file or directory in %sinclude_path.php on line %d
Warning: include(): Failed opening 'file2.php' for inclusion (include_path='%sphar://%stempmanifest1.phar.php/test') in %sinclude_path.php on line %d
-===DONE===
var_dump(ini_get('phar.require_hash'));
var_dump(ini_get('phar.readonly'));
?>
-===DONE===
--EXPECT--
string(1) "0"
string(1) "0"
bool(true)
string(1) "0"
string(1) "0"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
Invalid alias "hi\l" specified for phar "%sinvalid_alias.phar"
Invalid alias "hil;" specified for phar "%sinvalid_alias.phar"
Invalid alias ":hil" specified for phar "%sinvalid_alias.phar"
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
Cannot set alias ".phar/alias.txt" directly in phar "%sinvalid_setstubalias.phar.tar", use setAlias
Cannot set stub ".phar/stub.php" directly in phar "%sinvalid_setstubalias.phar.zip", use setStub
Cannot set alias ".phar/alias.txt" directly in phar "%sinvalid_setstubalias.phar.zip", use setAlias
-===DONE===
var_dump(file_get_contents($pname.'/'.$name));
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
string(1) "b"
string(1) "c"
string(1) "d"
-===DONE===
var_dump(file_get_contents($pname.'/'.$name));
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
string(1) "b"
string(1) "c"
string(1) "d"
-===DONE===
var_dump($phar[$name]->getMetadata());
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
string(3) "bar"
}
bool(true)
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
Warning: rmdir(): phar error: cannot remove directory "a" in phar "%smkdir.phar.php", phar error: path "a" exists and is a not a directory in %smkdir.php on line %d
Cannot create a directory in magic ".phar" directory
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tempmanifest1.phar.php');
Mounting of /notfound to %stests/this/does/not/exist within phar %stempmanifest1.phar.php failed
Mounting of /testit to %stests within phar %stests/tempmanifest1.phar.php failed
Mounting of /testit/extfile.php to %stests within phar %stests/tempmanifest1.phar.php failed
-===DONE===
<?php
include __DIR__ . '/files/nophar.phar';
?>
-===DONE===
--EXPECT--
in b
<?php include "b/c.php";
in d
-===DONE===
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
extra
-===DONE===
var_dump(fopen($pname . '/b/c.php', 'wb'));
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: fopen(phar://%sopen_for_write_existing_b.phar.php/b/c.php): failed to open stream: phar error: write operations disabled by the php.ini setting phar.readonly in %sopen_for_write_existing_b.php on line %d
bool(false)
This is b/c
-===DONE===
var_dump(fopen($pname . '/b/c.php', 'wb'));
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: fopen(phar://%sopen_for_write_existing_c.phar.php/b/c.php): failed to open stream: phar error: write operations disabled by the php.ini setting phar.readonly in %sopen_for_write_existing_c.php on line %d
bool(false)
This is b/c
-===DONE===
include $pname . '/b/new.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
This is b/c
extra
-===DONE===
include $pname . '/b/new.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sopen_for_write_newfile_b.phar.php/b/new.php' for inclusion (include_path='%s') in %sopen_for_write_newfile_b.php on line %d
-===DONE===
include $pname . '/b/new.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sopen_for_write_newfile_c.phar.php/b/new.php' for inclusion (include_path='%s') in %sopen_for_write_newfile_c.php on line %d
-===DONE===
opendir('phar://');
opendir('phar://hi.phar');
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: opendir(phar://hi.phar): failed to open dir: phar error: invalid url or non-existent phar "phar://hi.phar"
phar url "phar://hi.phar" is unknown in %sopendir.php on line %d
-===DONE===
include $pname . '/foo';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php rmdir(__DIR__ . '/poo');
foo
Warning: opendir(phar://%sopendir_edgecases.phar.php/oops): failed to open dir: %s in phar://%sopendir_edgecases.phar.php/foo on line %d
-===DONE===
include 'phar://phar_begin_setstub_commit.phar/b.php';
var_dump($p->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_begin_setstub_commit.phar');
string(5) "World"
string(%d) "<?php var_dump("Second"); Phar::mapPhar("phar_begin_setstub_commit.phar"); __HALT_COMPILER(); ?>
"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromdirectory1.phar');
--EXPECTF--
%s(24) "UnexpectedValueException"
Cannot write to archive - write operations restricted by INI setting
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromdirectory2.phar');
--EXPECTF--
%s(24) "UnexpectedValueException"
RecursiveDirectoryIterator::__construct(1,1): %s (code: 2)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromdirectory2.phar');
--EXPECTF--
%s(24) "UnexpectedValueException"
RecursiveDirectoryIterator::__construct(1): failed to open dir: No such file or directory
-===DONE===
var_dump(file_exists(__DIR__ . '/buildfromdirectory4.phar'));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromdirectory4.phar');
string(%d) "%stestdir4%cfile4.txt"
}
bool(true)
-===DONE===
var_dump(file_exists(__DIR__ . '/buildfromdirectory5.phar'));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromdirectory5.phar');
string(%d) "%stestdir5%cfile4.txt"
}
bool(true)
-===DONE===
var_dump(file_exists(__DIR__ . '/buildfromdirectory6.phar'));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromdirectory6.phar');
array(0) {
}
bool(false)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator1.phar');
--EXPECTF--
%s(24) "UnexpectedValueException"
Cannot write out phar archive, phar is read-only
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator10.phar');
["zip/corrupt_010.phpt"]=>
string(%d) "%szip%ccorrupt_010.phpt"
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator4.phar');
["a"]=>
string(%d) "%sphar_buildfromiterator4.phpt"
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator5.phar');
current
%s(24) "UnexpectedValueException"
Iterator myIterator returned an invalid value (must return a string)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator6.phar');
key
%s(24) "UnexpectedValueException"
Iterator myIterator returned an invalid key (must return a string)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator7.phar');
key
%s(24) "UnexpectedValueException"
Iterator myIterator returned a file that could not be opened "phar_buildfromiterator7./oopsie/there.phpt"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator8.phar');
["033.phpt"]=>
string(%d) "%s033.phpt"
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator9.phar');
["a"]=>
string(%d) "[stream]"
}
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/phar_bz2.phar');
bool(true)
bool(true)
Unknown file format specified
-===DONE===
?>");
var_dump($p->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_commitwrite.phar');
include 'phar://phar_commitwrite.phar/startup.php';
__HALT_COMPILER(); ?>
"
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--EXPECT--
Cannot create a phar archive from a URL like "http://should.fail.com". Phar objects can only be created from local files
Cannot create a phar archive from a URL like "http://". Phar objects can only be created from local files
Cannot create phar 'http:/', file extension (or combination) not recognised or the directory does not exist
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
data phar "%sphar_convert_again2.phar.tgz.oops" has invalid extension phar.tgz.oops
phar "%sphar_convert_again2.tgz.oops" has invalid extension tgz.oops
data phar "%sphar_convert_again2.phar/.tgz.oops" has invalid extension phar/.tgz.oops
-===DONE===
var_dump($phar->getAlias());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
string(60) "<?php // zip-based phar archive stub file
__HALT_COMPILER();"
NULL
-===DONE===
echo $e->getMessage()."\n";
}
?>
-===DONE===
--CLEAN--
<?php
echo __DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.gz' . "\n";
NULL
================= convertToPhar() ====================
Cannot write out executable phar archive, phar is read-only
-===DONE===
var_dump($phar->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
bool(true)
string(60) "<?php // tar-based phar archive stub file
__HALT_COMPILER();"
-===DONE===
var_dump($phar->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar.gz');
bool(true)
string(60) "<?php // tar-based phar archive stub file
__HALT_COMPILER();"
-===DONE===
var_dump($phar->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar.bz2');
bool(true)
string(60) "<?php // tar-based phar archive stub file
__HALT_COMPILER();"
-===DONE===
var_dump($phar->isFileFormat(Phar::ZIP));
var_dump($phar->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
bool(true)
string(60) "<?php // zip-based phar archive stub file
__HALT_COMPILER();"
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '2.phar.php'); ?>
hi
file "d" cannot be copied to file ".phar/stub.php", cannot copy to Phar meta-file in %sphar_copy2.phar.php
file ".phar/stub.php" cannot be copied to file "d", cannot copy Phar meta-file in %sphar_copy2.phar.php
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_create_in_cwd.phar');
include 'phar://phar_create_in_cwd.phar/startup.php';
__HALT_COMPILER(); ?>
"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
string(6641) "<?php
============================================================================
int(7032)
Illegal web filename passed in for stub creation, was 401 characters long, and only 400 or less is allowed
-===DONE===
var_dump($phar['b']->isCompressed());
var_dump($phar['b']->getMetaData());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
[0]=>
int(4)
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
%sphar_decompress.hooba.phar
Cannot decompress phar archive, phar is read-only
Cannot decompress zip-based archives with whole-archive compression
-===DONE===
var_dump($obj->getPathName());
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
string(%d) "phar://%sphar_dir_iterate.phar.php%canother.file.txt"
string(%d) "phar://%sphar_dir_iterate.phar.php/sub%ctop.txt"
string(%d) "phar://%sphar_dir_iterate.phar.php%ctop.txt"
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/broken.dirname/dotted_path.phar');
--EXPECT--
this is a
this is b
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
@rmdir(__DIR__ . '/whatever');
string(2) "hi"
Cannot extract to "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...", destination directory is too long for filesystem
Extraction from phar "%stempmanifest1.phar.php" failed: Cannot extract "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa..." to "%s...", extracted filename is too long for filesystem
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tempmanifest2.phar.php');
%sextract2%csubdir
%sextract2%csubdir%cectory
%sextract2%csubdir%cectory%cfile.txt
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
$dir = __DIR__ . '/test-extract3/';
Invalid argument, %sfiles/bogus.zip cannot be found
phar://%sfiles/notbogus.zip%cnonsense.txt
phar://%sfiles/notbogus.zip%cstuff.txt
-===DONE===
<?php
var_dump(Phar::getSupportedSignatures());
?>
-===DONE===
-?>
--EXPECT--
array(4) {
[0]=>
[3]=>
string(7) "SHA-512"
}
-===DONE===
<?php
var_dump(Phar::getSupportedSignatures());
?>
-===DONE===
--EXPECT--
array(5) {
[0]=>
[4]=>
string(7) "OpenSSL"
}
-===DONE===
<?php
var_dump(Phar::getSupportedCompression());
?>
-===DONE===
--EXPECT--
array(2) {
[0]=>
[1]=>
string(5) "BZIP2"
}
-===DONE===
<?php
var_dump(Phar::getSupportedCompression());
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(5) "BZIP2"
}
-===DONE===
<?php
var_dump(Phar::getSupportedCompression());
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(2) "GZ"
}
-===DONE===
<?php
var_dump(Phar::getSupportedCompression());
?>
-===DONE===
--EXPECT--
array(0) {
}
-===DONE===
');
include $pname . '/foo/hi';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.php'); ?>
Warning: opendir(foo/hi,foo/hi): %s (code: 3) in phar://%sphar_gobyebye-win32.phar.php/foo/hi on line %d
Warning: opendir(foo/hi): failed to open dir: No such file or directory in phar://%sphar_gobyebye-win32.phar.php/foo/hi on line %d
-===DONE===
');
include $pname . '/foo/hi';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.php'); ?>
bool(false)
Warning: opendir(foo/hi): failed to open dir: No such file or directory in phar://%sphar_gobyebye.phar.php/foo/hi on line %d
-===DONE===
var_dump($b->isFileFormat(Phar::PHAR));
var_dump($b->isCompressed() == Phar::GZ);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/phar_gzip.phar');
string(%d) "phar://%sphar_gzip.phar/tar_004.php"
bool(true)
bool(true)
-===DONE===
var_dump(Phar::isValidPharFilename('dir.phar.php', false));
?>
-===DONE===
--CLEAN--
<?php
rmdir(__DIR__ . '/.phar');
bool(true)
bool(true)
bool(false)
-===DONE===
__HALT_COMPILER();');
include $fname;
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
in b
<?php include "b/c.php";
in d
-===DONE===
var_dump(file_get_contents($pname.'/'.$name));
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
string(1) "b"
string(1) "c"
string(1) "d"
-===DONE===
var_dump(file_get_contents($pname.'/'.$name));
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
string(1) "b"
string(1) "c"
string(1) "d"
-===DONE===
Phar::mount($pname . '/testit2', $pname . '/testit1');
echo substr($a['testit2']->getContent(),0, 50),"\n";
?>
-===DONE===
--CLEAN--
<?php unlink(dirname(__FILE__) . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(dirname(__FILE__) . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
Mounting of /oops to /home/oops/../../etc/passwd: within phar %sphar_mount.phar.php failed
<?php
$fname = dirname(__FILE__) . '/' . basename(
-===DONE===
var_dump($phar->getAlias());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Cannot set alias ".phar/alias.txt" directly in phar "%sphar_offset_check.phar.php", use setAlias
string(5) "susan"
string(5) "susan"
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECT--
foobar
Cannot set any files or directories in magic ".phar" directory
Entry .phar/stub.php does not exist
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_001.phar.php');
int(5)
string(50) "Cannot call method on an uninitialized Phar object"
string(29) "Cannot call constructor twice"
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_002.phar.php');
bool(false)
NULL
int(0)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_003.phar.php');
string(5) "e.php"
string(32) "<?php echo "This is e.php\n"; ?>"
This is e.php
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_004.phar.php');
string(5) "e.php"
MyDirectoryIterator::next
MyDirectoryIterator::valid
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_005.phar.php');
string(0) ""
string(5) "e.php"
string(20) "phar_oo_005.phar.php"
-===DONE===
echo $phar['b.php']->getFilename() . "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_006.phar.php');
c.php
MyFile::__construct(phar://%s/b.php)
b.php
-===DONE===
//unset($f); without unset we check for working refcounting
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_007.phar.php');
bool(false)
string(32) "<?php echo "This is a.php\n"; ?>"
bool(true)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_008.phar.php');
3=>2|a|b
MyCSVFile2::getCurrentLine
5=>3|c|'e'
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_009.phar.php');
3=>4
4=>5|5
6=>7|777
-===DONE===
var_dump(isset($phar['b']));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_010.phar.php');
bool(false)
bool(false)
bool(true)
-===DONE===
echo "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_011.phar.php');
bool(true)
bool(true)
hi
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_011b.phar.php');
?>
--EXPECT--
Exception: Write operations disabled by the php.ini setting phar.readonly
-===DONE===
var_dump(isset($phar['f.php']));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_012.phar.php');
bool(true)
hi
bool(false)
-===DONE===
var_dump(isset($phar['f.php']));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_012_confirm.phar.php');
bool(true)
hi
bool(false)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_012b.phar.php');
?>
--EXPECT--
Exception: Write operations disabled by the php.ini setting phar.readonly
-===DONE===
var_dump($phar['b']->isCompressed(Phar::BZ2));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
string(1) "c"
bool(false)
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
bool(true)
bool(false)
Unknown compression specified, please pass one of Phar::GZ or Phar::BZ2
-===DONE===
var_dump($phar['d']->isCompressed());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(false)
string(5) "new d"
bool(false)
-===DONE===
var_dump($phar['d']->isCompressed());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(false)
string(5) "new d"
bool(false)
-===DONE===
var_dump($phar['e']->isCompressed());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(false)
string(5) "new e"
bool(true)
-===DONE===
var_dump($phar['e']->isCompressed());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(false)
string(5) "new e"
bool(true)
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
this works
Phar error: Cannot retrieve contents, "a" in phar "%sphar_oo_getcontents.phar.php" is a directory
Phar error: Cannot retrieve contents, "hi" in phar "%sphar_oo_getcontents.phar.php" is a directory
-===DONE===
var_dump($phar2['a']->isCompressed());
echo $phar2['a']->getContent() . "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(true)
file contents
this works
-===DONE===
$phar->compressFiles(Phar::GZ);
var_dump($phar->getModified());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
--EXPECT--
bool(false)
bool(true)
-===DONE===
var_dump($b->isWritable());
chmod($fname2, 0666);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.1.phar.php');
bool(true)
bool(false)
bool(false)
-===DONE===
$phar = new Phar($fname);
var_dump($phar->getSignature());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/files/phar_oo_test.phar.php');
?>
--EXPECT--
bool(false)
-===DONE===
var_dump($phar['a']->isCompressed());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
bool(false)
string(1) "c"
bool(false)
-===DONE===
include $pname . '/index.php';
var_dump(Phar::running());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
string(%d) "phar://%sphar_running.phar.php"
string(%d) "%sphar_running.phar.php"
string(0) ""
-===DONE===
$phar->setAlias('test');
echo $phar->getAlias() . "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
--EXPECT--
hio
test
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
test
alias "test" is already used for archive "%sphar_setalias2.phar.php" and cannot be used for other archives
alias "test" is already used for archive "%sphar_setalias2.phar.php" cannot be overloaded with "%snope.phar"
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
============================================================================
int(7034)
Illegal filename passed in for stub creation, was 401 characters long, and only 400 or less is allowed
-===DONE===
echo $e->getMessage();
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
["hash_type"]=>
string(7) "OpenSSL"
}
-===DONE===
fclose($fp);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
<?php echo "third stub\n"; __HALT_COMPILER(); ?>booya
<?php echo "third stub\n"; __HALT_COMPILER(); ?>
<?php echo "third stub\n"; __HALT_COMPILER(); ?>
-===DONE===
var_dump($phar->getStub() == $stub);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(true)
string(48) "<?php echo "first stub\n"; __HALT_COMPILER(); ?>"
bool(true)
-===DONE===
var_dump($phar->getStub() == $sexp);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(true)
bool(false)
bool(true)
-===DONE===
var_dump($phar->getStub() == $sexp);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php');
bool(true)
bool(false)
bool(true)
-===DONE===
unset($phar);
include $pname . '/evil.php';
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
phar archive "%sphar_unlinkarchive.phar" cannot be unlinked from within itself
string(%d) "%sphar_unlinkarchive.phar"
hi
-===DONE===
lstat($pname . '/a/b'); // sets BG(CurrentLStatFile)
$b->chmod(0666);
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar'); ?>
--EXPECTF--
Phar entry "a" is a temporary directory (not an actual entry in the archive), cannot chmod
-===DONE===
var_dump($b->decompress());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar'); ?>
Phar entry is a directory, cannot set compression
bool(true)
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar'); ?>
--EXPECTF--
Cannot access phar file entry '%s' in archive '%s'
Cannot call constructor twice
'%s' is not a valid phar archive URL (must have at least phar://filename.phar)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar'); ?>
--EXPECTF--
Phar entry is a directory, does not have a CRC
Phar entry was not CRC checked
int(%s)
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar'); ?>
Phar entry is a temporary directory (not an actual entry in the archive), cannot delete metadata
Write operations disabled by the php.ini setting phar.readonly
Write operations disabled by the php.ini setting phar.readonly
-===DONE===
ini_set('phar.require_hash',1);
phpinfo(INFO_MODULES);
?>
-===DONE===
--EXPECTF--
%aPhar
phar.readonly => On => Off
phar.require_hash => On => Off
%a
-===DONE===
<?php
phpinfo(INFO_MODULES);
?>
-===DONE===
--EXPECTF--
%a
Phar
phar.readonly => On => On
phar.require_hash => On => On
%a
-===DONE===
<?php
phpinfo(INFO_MODULES);
?>
-===DONE===
--EXPECTF--
%a
Phar
phar.readonly => On => On
phar.require_hash => On => On
%a
-===DONE===
');
include $pname . '/foo/hi';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php rmdir(__DIR__ . '/poo'); ?>
?>
Warning: readfile(phar://%sreadfile_edgecases.phar.php/oops): failed to open stream: phar error: path "oops" is a directory in phar://%sreadfile_edgecases.phar.php/foo/hi on line %d
-===DONE===
include $pname . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
}
string(5) "extra"
extra
-===DONE===
ini_set('phar.readonly', 1);
include $fname2;
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.1.php'); ?>
--EXPECT--
bool(false)
Write operations disabled by the php.ini setting phar.readonly
-===DONE===
__HALT_COMPILER();');
include $fname;
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
--EXPECTF--
Warning: fileperms(): stat failed for not/found in phar://%sstat.phar.php/my/index.php on line %d
bool(false)
-===DONE===
__HALT_COMPILER();');
include $fname3;
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar'); ?>
dir
bool(true)
bool(false)
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
bool(true)
bool(false)
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
--EXPECTF--
bool(false)
Cannot modify permissions for file "a.php" in phar "%s033a.phar.tar", write operations are prohibited
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
2
phar error: Unable to add tar-based phar "%salias_acrobatics.2.phar.tar", alias is already in use
alias "another" is already used for archive "%salias_acrobatics.phar.tar" cannot be overloaded with "%salias_acrobatics.phar.tar"
-===DONE===
var_dump($phar->getMetadata());
var_dump($phar['a']->getMetadata());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.phar.tar.php'); ?>
--EXPECT--
string(4) "hime"
string(8) "hi there"
string(6) "a meta"
-===DONE===
}
}
?>
-===DONE===
--EXPECTF--
phar error: invalid alias "hi/thereaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa..." in tar-based phar "%sbadalias1.phar.tar"
phar error: invalid alias "hi\there" in tar-based phar "%sbadalias2.phar.tar"
phar error: invalid alias "hi;there" in tar-based phar "%sbadalias3.phar.tar"
phar error: invalid alias "hi:there" in tar-based phar "%sbadalias4.phar.tar"
phar error: tar-based phar "%sbadalias5.phar.tar" has alias that is larger than 511 bytes, cannot process
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar');
?>
--EXPECTF--
phar error: "%sbadchecksum.tar" is a corrupted tar file (checksum mismatch of file "hithere")
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar');
tar-based phar "%sbignames.2.tar" cannot be created, filename "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" is too long for tar file format
tar-based phar "%sbignames.3.tar" cannot be created, filename "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" is too long for tar file format
tar-based phar "%sbignames.4.tar" cannot be created, filename "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" is too long for tar file format
-===DONE===
echo $p1[str_repeat('a', 155) . '/' . str_repeat('a', 100)]->getContent() . "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar');
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
hi
hi2
-===DONE===
}
print_r($files);
?>
-===DONE===
--EXPECT--
Array
(
[27] => phar://*/Structures_Graph-1.0.3/tests/testCase/BasicGraph.php
[28] => phar://*/package.xml
)
-===DONE===
$phar = new PharData(__DIR__."/files/bug64343.tar");
?>
-===DONE===
--EXPECT--
Test
-===DONE===
?>
-===DONE===
--EXPECT--
Test
#!/usr/bin/env php
Test
-===DONE===
include $pname . '/b.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar.php'); ?>
--EXPECT--
bool(true)
modified!
another!
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.tar/a.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%screate_new_phar_b.phar.tar/a.php' for inclusion (include_path='%s') in %screate_new_phar_b.php on line %d
-===DONE===
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sdelete_in_phar.phar.tar/b/c.php' for inclusion (include_path='%s') in %sdelete_in_phar.php on line %d
-===DONE===
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
This is b
This is b/c
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.tar/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sdelete_in_phar_confirm.phar.tar/b/c.php' for inclusion (include_path='%s') in %sdelete_in_phar_confirm.php on line %d
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
?>
--EXPECTF--
phar tar error: "%sexists_as_phar.phar.tar" already exists as a regular phar and must be deleted from disk prior to creating as a tar-based phar
-===DONE===
$p['testit/link'] = 'overwriting';
var_dump($p['testit/link']->getContent());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar');
string(3) "hi
"
string(11) "overwriting"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.tar');
?>
--EXPECTF--
phar error: "%slinks2.tar" is a corrupted tar file - hard link to non-existent file "internal/file.txt"
-===DONE===
echo $p['file.txt']->getContent();
echo $p['my/file']->getContent();
?>
-===DONE===
--EXPECT--
my file
my file
-===DONE===
echo $p['file.txt']->getContent();
echo $p['link.txt']->getContent();
?>
-===DONE===
--EXPECT--
hi
hi
-===DONE===
echo $p['hi/test.txt']->getContent();
echo $p['hi/link.txt']->getContent();
?>
-===DONE===
--EXPECT--
hi
hi
-===DONE===
fseek($a, 3);
echo fread($a, 10);
?>
-===DONE===
--EXPECT--
hi there
there
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECT--
extra
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
bool(false)
This is b/c
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
bool(false)
This is b/c
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECT--
This is b/c
extra
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sopen_for_write_newfile_b.phar.tar/b/new.php' for inclusion (include_path='%s') in %sopen_for_write_newfile_b.php on line %d
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sopen_for_write_newfile_c.phar.tar/b/new.php' for inclusion (include_path='%s') in %sopen_for_write_newfile_c.php on line %d
-===DONE===
include 'phar://phar_begin_setstub_commit.phar/b.php';
var_dump($p->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_begin_setstub_commit.phar.tar');
string(5) "World"
string(%d) "<?php var_dump("Second"); Phar::mapPhar("phar_begin_setstub_commit.phar"); __HALT_COMPILER(); ?>
"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.tar');
string(%d) "%sphar_buildfromiterator4.phpt"
}
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.tar');
current
%s(24) "UnexpectedValueException"
Iterator myIterator returned an invalid value (must return a string)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.tar');
key
%s(24) "UnexpectedValueException"
Iterator myIterator returned an invalid key (must return a string)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.tar');
key
%s(24) "UnexpectedValueException"
Iterator myIterator returned a file that could not be opened "phar_buildfromiterator7./oopsie/there.phpt"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.tar');
string(%d) "%sfrontcontroller9.phar.phpt"
}
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.tar');
["a"]=>
string(%d) "[stream]"
}
-===DONE===
var_dump($p->getStub());
var_dump($p->isFileFormat(Phar::TAR));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_commitwrite.phar.tar');
__HALT_COMPILER(); ?>
"
bool(true)
-===DONE===
var_dump(strlen($phar->getStub()));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
int(6641)
bool(true)
int(6641)
-===DONE===
var_dump(strlen($phar->getStub()));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
bool(true)
bool(true)
int(6641)
-===DONE===
var_dump(strlen($phar->getStub()));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.bz2');
bool(true)
bool(true)
int(6641)
-===DONE===
var_dump($phar->getMetadata());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.gz');
bool(true)
int(6641)
string(2) "hi"
-===DONE===
__HALT_COMPILER();');
include $fname;
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar.php');
in b
<?php include "b/c.php";
in d
-===DONE===
echo $a->getAlias() . "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
hio
test
test
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
hio
test
alias "test" is already used for archive "%sphar_setalias2.phar.tar" and cannot be used for other archives
-===DONE===
var_dump($phar->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
Warning: Phar::setDefaultStub(): method accepts no arguments for a tar- or zip-based phar stub, 2 given in %sphar_setdefaultstub.php on line %d
string(60) "<?php // tar-based phar archive stub file
__HALT_COMPILER();"
-===DONE===
echo $e->getMessage();
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
["hash_type"]=>
string(7) "OpenSSL"
}
-===DONE===
echo $phar->getStub();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar.php');
<?php echo "third stub\n"; __HALT_COMPILER(); ?>booya
<?php echo "third stub\n"; __HALT_COMPILER(); ?>
<?php echo "third stub\n"; __HALT_COMPILER(); ?>
-===DONE===
var_dump($phar->getStub() == $stub);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
string(50) "<?php echo "first stub\n"; __HALT_COMPILER(); ?>
"
bool(true)
-===DONE===
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar'); ?>
--EXPECTF--
}
string(5) "extra"
extra
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/require_hash.phar.tar');
["hash_type"]=>
string(3) "MD5"
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_001.phar.tar');
--EXPECTF--
Warning: fopen(phar://%star_001.phar.tar/tar_001.phpt): failed to open stream: phar error: "%star_001.phar.tar" is a corrupted tar file (truncated) in %star_001.php on line 9
phar error: "%star_001.phar.tar" is a corrupted tar file (truncated)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_002.phar.tar');
--EXPECTF--
Warning: fopen(phar://%star_002.phar.tar/tar_002.phpt): failed to open stream: phar error: "%star_002.phar.tar" is a corrupted tar file (truncated) in %star_002.php on line 9
phar error: "%star_002.phar.tar" is a corrupted tar file (truncated)
-===DONE===
closedir($tar);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_003.phar.tar');
internal
file
tar_003.phpt
-===DONE===
include $fname;
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_004.phar.tar');
--EXPECTF--
string(9) "it worked"
string(%d) "phar://%star_004.phar.tar/tar_004.php"
-===DONE===
var_dump($phar2->isCompressed() == Phar::BZ2);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_bz2.phar');
string(%d) "phar://%star_bz2.phar/tar_004.php"
bool(true)
bool(true)
-===DONE===
var_dump($b->isFileFormat(Phar::TAR));
var_dump($b->isCompressed() == Phar::GZ);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_gzip.phar');
string(%d) "phar://%star_gzip.phar/tar_004.php"
bool(true)
bool(true)
-===DONE===
var_dump($phar2->isCompressed() == Phar::BZ2);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_makebz2.phar.bz2');
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump($phar2->isCompressed() == Phar::GZ);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_makegz.phar.gz');
bool(true)
bool(true)
bool(true)
-===DONE===
}
?>
-===DONE===
--EXPECT--
string(0) ""
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/tar_nostub.phar.tar');
RecursiveDirectoryIterator::__construct(phar://%star_nostub.phar.tar/): failed to open dir: '%star_nostub.phar.tar' is not a phar archive. Use PharData::__construct() for a standard zip or tar archive
phar url "phar://%star_nostub.phar.tar/" is unknown
string(0) ""
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.tar');
?>
--EXPECTF--
phar error: "%strunc.tar" is a corrupted tar file (truncated)
-===DONE===
$a = file_get_contents($pname . '/file1.txt'); // this fails because $fname2 ref exists
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.phar.php'); ?>
string(5) "first"
Warning: file_get_contents(phar://%sfile1.txt): failed to open stream: Cannot open archive "%stest_alias_unset.phar.php", alias is already in use by existing archive in %stest_alias_unset.php on line %d
-===DONE===
$r = $a->getSignature();
var_dump($r['hash_type']);
?>
-===DONE===
--EXPECT--
string(5) "SHA-1"
string(7) "SHA-512"
string(7) "SHA-256"
string(3) "MD5"
string(7) "OpenSSL"
-===DONE===
var_dump(file_exists($fname));
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.phar.php'); ?>
NULL
string(%d) "%stest_unset.phar.php"
bool(false)
-===DONE===
<?php
include __DIR__ . '/files/nophar.phar';
?>
-===DONE===
--EXPECT--
in b
<?php include "b/c.php";
in d
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/zfapp.tgz');
phar://%szfapp.phar.tar.gz/application/default/views/scripts/index/index.phtml
phar://%szfapp.phar.tar.gz/html/.htaccess
phar://%szfapp.phar.tar.gz/html/index.php
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
bool(true)
bool(false)
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
--EXPECTF--
bool(false)
Cannot modify permissions for file "a.php" in phar "%sa.phar.zip", write operations are prohibited
-===DONE===
echo $e->getMessage(),"\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
2
phar error: Unable to add zip-based phar "%salias_acrobatics.2.phar.zip" with implicit alias, alias is already in use
alias "another" is already used for archive "%salias_acrobatics.phar.zip" cannot be overloaded with "%salias_acrobatics.phar.zip"
-===DONE===
var_dump($phar->getMetadata());
var_dump($phar['a']->getMetadata());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.phar.zip.php'); ?>
string(4) "hime"
string(8) "hi there"
string(6) "a meta"
-===DONE===
}
}
?>
-===DONE===
--EXPECTF--
phar error: invalid alias "hi/there" in zip-based phar "%sbadalias1.phar.zip"
phar error: invalid alias "hi\there" in zip-based phar "%sbadalias2.phar.zip"
phar error: invalid alias "hi\there" in zip-based phar "%sbadalias3.phar.zip"
phar error: invalid alias "hi;there" in zip-based phar "%sbadalias4.phar.zip"
phar error: invalid alias "hi:there" in zip-based phar "%sbadalias5.phar.zip"
-===DONE===
<?php
echo file_get_contents('phar://' . __DIR__ . '/files/test.odt/content.xml'), "\n";
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<office:document-content xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rpt="http://openoffice.org/2005/report" xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:rdfa="http://docs.oasis-open.org/opendocument/meta/rdfa#" office:version="1.2"><office:scripts/><office:font-face-decls><style:font-face style:name="OpenSymbol" svg:font-family="OpenSymbol"/><style:font-face style:name="Tahoma1" svg:font-family="Tahoma"/><style:font-face style:name="Times New Roman" svg:font-family="'Times New Roman'" style:font-family-generic="roman" style:font-pitch="variable"/><style:font-face style:name="Arial" svg:font-family="Arial" style:font-family-generic="swiss" style:font-pitch="variable"/><style:font-face style:name="Arial Unicode MS" svg:font-family="'Arial Unicode MS'" style:font-family-generic="system" style:font-pitch="variable"/><style:font-face style:name="MS Mincho" svg:font-family="'MS Mincho'" style:font-family-generic="system" style:font-pitch="variable"/><style:font-face style:name="Tahoma" svg:font-family="Tahoma" style:font-family-generic="system" style:font-pitch="variable"/></office:font-face-decls><office:automatic-styles><style:style style:name="P1" style:family="paragraph" style:parent-style-name="Standard" style:list-style-name="L1"/><style:style style:name="T1" style:family="text"><style:text-properties style:font-name="Arial"/></style:style><text:list-style style:name="L1"><text:list-level-style-bullet text:level="1" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.27cm" fo:text-indent="-0.635cm" fo:margin-left="1.27cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="2" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="◦"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.905cm" fo:text-indent="-0.635cm" fo:margin-left="1.905cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="3" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="▪"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.54cm" fo:text-indent="-0.635cm" fo:margin-left="2.54cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="4" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.175cm" fo:text-indent="-0.635cm" fo:margin-left="3.175cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="5" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="◦"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.81cm" fo:text-indent="-0.635cm" fo:margin-left="3.81cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="6" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="▪"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.445cm" fo:text-indent="-0.635cm" fo:margin-left="4.445cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="7" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.08cm" fo:text-indent="-0.635cm" fo:margin-left="5.08cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="8" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="◦"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.715cm" fo:text-indent="-0.635cm" fo:margin-left="5.715cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="9" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="▪"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.35cm" fo:text-indent="-0.635cm" fo:margin-left="6.35cm"/></style:list-level-properties></text:list-level-style-bullet><text:list-level-style-bullet text:level="10" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•"><style:list-level-properties text:list-level-position-and-space-mode="label-alignment"><style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.985cm" fo:text-indent="-0.635cm" fo:margin-left="6.985cm"/></style:list-level-properties></text:list-level-style-bullet></text:list-style></office:automatic-styles><office:body><office:text><text:sequence-decls><text:sequence-decl text:display-outline-level="0" text:name="Illustration"/><text:sequence-decl text:display-outline-level="0" text:name="Table"/><text:sequence-decl text:display-outline-level="0" text:name="Text"/><text:sequence-decl text:display-outline-level="0" text:name="Drawing"/></text:sequence-decls><text:h text:style-name="Heading_20_1" text:outline-level="1">Überschrift</text:h><text:list xml:id="list38593008" text:style-name="L1"><text:list-item><text:p text:style-name="P1"><text:span text:style-name="T1">Name:<text:tab/><text:tab/>$$n_fn$$</text:span></text:p></text:list-item><text:list-item><text:p text:style-name="P1"><text:span text:style-name="T1">Firma:<text:tab/><text:tab/>$$org_name$$</text:span></text:p></text:list-item><text:list-item><text:p text:style-name="P1"><text:span text:style-name="T1">Menge:<text:tab/>$$#menge$$</text:span></text:p></text:list-item></text:list></office:text></office:body></office:document-content>
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
<?php
include dirname(__FILE__) . '/corrupt_zipmaker.php.inc';
$a->writeZip(dirname(__FILE__) . '/compress_unsupunknown.zip');
?>
string(175) "hitheresuperlongzipistoostupidtodowhatIsaysoIhavetousethisridiculouslylongaliasbecauseitisstupiddidImentionthatalreadythemadnessdoesnotstopIhateinfozipIhateinfozipIhateinfozip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: corrupt zip archive, conflicting file count in end of central directory record in zip-based phar "%scount1.zip"
phar error: corrupt zip archive, conflicting file count in end of central directory record in zip-based phar "%scount2.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: end of central directory not found in zip-based phar "%snozipend.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: corrupt zip archive, zip file comment truncated in zip-based phar "%sfilecomment.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: corrupted central directory entry, no magic signature in zip-based phar "%scdir_offset.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: Cannot process encrypted zip files in zip-based phar "%sencrypted.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: Cannot process zips created from stdin (zero-length filename) in zip-based phar "%sstdin.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: corrupted central directory entry, no magic signature in zip-based phar "%struncfilename.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: unsupported compression method (Shrunk) used in this zip in zip-based phar "%scompress_unsup1.zip"
phar error: unsupported compression method (Reduce) used in this zip in zip-based phar "%scompress_unsup2.zip"
phar error: unsupported compression method (WavPack) used in this zip in zip-based phar "%scompress_unsup97.zip"
phar error: unsupported compression method (PPMd) used in this zip in zip-based phar "%scompress_unsup98.zip"
phar error: unsupported compression method (unknown) used in this zip in zip-based phar "%scompress_unsupunknown.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: Unable to process extra field header for file in central directory in zip-based phar "%sextralen_toolong.zip"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar error: split archives spanning multiple zips cannot be processed in zip-based phar "%sdisknumber.zip"
-===DONE===
include $pname . '/b.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php'); ?>
--EXPECT--
bool(true)
modified!
another!
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.zip/a.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%screate_new_phar_b.phar.zip/a.php' for inclusion (include_path='%s') in %screate_new_phar_b.php on line %d
-===DONE===
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sdelete_in_phar.phar.zip/b/c.php' for inclusion (include_path='%s') in %sdelete_in_phar.php on line %d
-===DONE===
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
This is b
This is b/c
-===DONE===
include 'phar://' . __DIR__ . '/' . basename(__FILE__, '.php') . '.phar.zip/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sdelete_in_phar_confirm.phar.zip/b/c.php' for inclusion (include_path='%s') in %sdelete_in_phar_confirm.php on line %d
-===DONE===
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
?>
--EXPECTF--
phar zip error: phar "%sexists_as_phar.phar.zip" already exists as a regular phar and must be deleted from disk prior to creating as a zip-based phar
-===DONE===
var_dump($phar->getAlias());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
Cannot set alias ".phar/alias.txt" directly in phar "%sgetalias.phar.zip", use setAlias
string(13) "jiminycricket"
string(9) "pinocchio"
-===DONE===
$p2 = new Phar($fname2);
var_dump(strlen($p2['big']->getContent()));
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php'); ?>
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.2.phar.zip.php'); ?>
--EXPECT--
int(200000)
-===DONE===
}
var_dump($phar->getMetadata());
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php'); ?>
--EXPECT--
}
bool(true)
string(2) "hi"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
phar://%sodt.odt/Configurations2/accelerator%ccurrent.xml
phar://%sodt.odt/META-INF%cmanifest.xml
phar://%sodt.odt%csettings.xml
phar://%sodt.odt%cstyles.xml
Cannot create phar '%sodt.odt', file extension (or combination) not recognised or the directory does not exist
-===DONE===
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECT--
extra
-===DONE===
var_dump(fopen($alias . '/b/c.php', 'wb'));
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: fopen(phar://%sopen_for_write_existing_b.phar.zip/b/c.php): failed to open stream: phar error: write operations disabled by the php.ini setting phar.readonly in %sopen_for_write_existing_b.php on line %d
bool(false)
This is b/c
-===DONE===
var_dump(fopen($alias . '/b/c.php', 'wb'));
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: fopen(phar://%sopen_for_write_existing_c.phar.zip/b/c.php): failed to open stream: phar error: write operations disabled by the php.ini setting phar.readonly in %sopen_for_write_existing_c.php on line %d
bool(false)
This is b/c
-===DONE===
include $alias . '/b/new.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECT--
This is b/c
extra
-===DONE===
include $alias . '/b/new.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sopen_for_write_newfile_b.phar.zip/b/new.php' for inclusion (include_path='%s') in %sopen_for_write_newfile_b.php on line %d
-===DONE===
include $alias . '/b/new.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
Warning: include(): Failed opening 'phar://%sopen_for_write_newfile_c.phar.zip/b/new.php' for inclusion (include_path='%s') in %sopen_for_write_newfile_c.php on line %d
-===DONE===
var_dump($p->getStub());
fclose($a);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_begin_setstub_commit.phar.zip');
"
string(%d) "<?php var_dump("First resource"); Phar::mapPhar("phar_begin_setstub_commit.phar"); __HALT_COMPILER(); ?>
"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.zip');
string(%d) "%sphar_buildfromiterator4.phpt"
}
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.zip');
current
%s(24) "UnexpectedValueException"
Iterator myIterator returned an invalid value (must return a string)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.zip');
key
%s(24) "UnexpectedValueException"
Iterator myIterator returned an invalid key (must return a string)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.zip');
key
%s(24) "UnexpectedValueException"
Iterator myIterator returned a file that could not be opened "phar_buildfromiterator7./oopsie/there.phpt"
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar.zip');
string(%d) "%sfrontcontroller9.phar.phpt"
}
bool(true)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/buildfromiterator.phar');
["a"]=>
string(%d) "[stream]"
}
-===DONE===
var_dump($p->getStub());
var_dump($p->isFileFormat(Phar::ZIP));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/phar_commitwrite.phar.zip');
__HALT_COMPILER(); ?>
"
bool(true)
-===DONE===
var_dump(strlen($phar->getStub()));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar');
int(6641)
bool(true)
int(6641)
-===DONE===
__HALT_COMPILER();');
include $pname;
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php');
in b
<?php include "b/c.php";
in d
-===DONE===
var_dump($c['a']->isCompressed(Phar::BZ2));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php');
string(1) "a"
bool(false)
bool(true)
-===DONE===
var_dump($phar['c']->isCompressed(Phar::GZ));
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php');
string(1) "c"
bool(false)
bool(true)
-===DONE===
$p3 = new Phar($fname3);
echo $p3->getAlias(), "\n";
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
test
test
test
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
hio
test
alias "test" is already used for archive "%sphar_setalias2.phar.zip" and cannot be used for other archives
-===DONE===
var_dump($phar->getStub());
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
Warning: Phar::setDefaultStub(): method accepts no arguments for a tar- or zip-based phar stub, 2 given in %sphar_setdefaultstub.php on line %d
string(60) "<?php // zip-based phar archive stub file
__HALT_COMPILER();"
-===DONE===
echo $e->getMessage();
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
["hash_type"]=>
string(7) "OpenSSL"
}
-===DONE===
echo $phar->getStub();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip.php');
<?php echo "third stub\n"; __HALT_COMPILER(); ?>booya
<?php echo "third stub\n"; __HALT_COMPILER(); ?>
<?php echo "third stub\n"; __HALT_COMPILER(); ?>
-===DONE===
var_dump($phar->getStub() == $stub);
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip');
string(50) "<?php echo "first stub\n"; __HALT_COMPILER(); ?>
"
bool(true)
-===DONE===
include $alias . '/b/c.php';
?>
-===DONE===
--CLEAN--
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.zip'); ?>
--EXPECTF--
}
string(5) "extra"
extra
-===DONE===
echo $a['notempty/hi.txt']->getPathName() . "\n";
}
?>
-===DONE===
--EXPECTF--
dir phar://%s/zip.zip%cempty
phar://%s/zip.zip%chi.txt
dir phar://%s/zip.zip%cnotempty
phar://%s/zip.zip/notempty%chi.txt
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
string(175) "hitheresuperlongzipistoostupidtodowhatIsaysoIhavetousethisridiculouslylongaliasbecauseitisstupiddidImentionthatalreadythemadnessdoesnotstopIhateinfozipIhateinfozipIhateinfozip"
-===DONE===
$info = posix_getgrnam($name);
var_dump(is_array($info));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
<?php
var_dump(posix_ctermid());
?>
-===DONE===
--EXPECTF--
string(%d) "%s"
-===DONE===
}
var_dump($grp['gid']);
?>
-===DONE===
--EXPECT--
int(0)
-===DONE===
print_r($groupinfo);
?>
-===DONE===
--EXPECTF--
Basic test of POSIX getgid and getgrid fucntions
Array
[gid] => %d
)
-===DONE===
$grp = posix_getgrgid(-1);
var_dump($grp['name']);
?>
-===DONE===
--EXPECT--
string(7) "nogroup"
-===DONE===
}
?>
-===DONE===
--EXPECT--
Basic test of POSIX getgroups
TEST PASSED
-===DONE===
var_dump( is_long(posix_getsid($pid)) );
?>
-===DONE===
--EXPECT--
*** Testing posix_getsid() : function test ***
-- Testing posix_getsid() function with current process pid --
bool(true)
-===DONE===
<?php
var_dump( posix_getsid(-1) );
?>
-===DONE===
--EXPECTF--
bool(false)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Test by calling method or function with its expected arguments ***
bool(true)
-===DONE===
var_dump(posix_setgid( $var ) );
}
?>
-===DONE===
--EXPECT--
*** Test substituting argument 1 with boolean values ***
bool(false)
bool(false)
bool(false)
bool(false)
-===DONE===
var_dump(posix_setgid( $var ) );
}
?>
-===DONE===
--EXPECT--
*** Test substituting argument 1 with int values ***
bool(false)
bool(false)
bool(false)
-===DONE===
<?php
var_dump(posix_times());
?>
-===DONE===
--EXPECTF--
array(5) {
["ticks"]=>
["cstime"]=>
int(%d)
}
-===DONE===
var_dump(posix_ttyname(STDERR));
var_dump(posix_ttyname(STDOUT));
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
bool(false)
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECT--
bool(false)
posix_ttyname(): supplied resource is not a valid stream resource
-===DONE===
var_dump($props);
var_dump($r->name);
?>
-===DONE===
--EXPECT--
array(0) {
}
string(4) "name"
}
string(17) "ReflectionClassEx"
-===DONE===
var_dump($r->bar);
?>
-===DONE===
--EXPECT--
ReflectionMethodEx::__construct
string(26) "ReflectionFunctionAbstract"
string(7) "getName"
string(3) "bar"
string(3) "baz"
-===DONE===
$r->invoke($o);
?>
-===DONE===
--EXPECT--
Foo::Test
-===DONE===
}
?>
-===DONE===
--EXPECT--
string(19) "Comment for class A"
string(15) "Method A::bla()"
bool(false)
bool(false)
string(22) "* Comment for A::baz()"
-===DONE===
TestDerived::testing();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
string(3) "pub"
string(3) "pub"
string(7) "updated"
EXCEPTION
EXCEPTION
-===DONE===
test('WithCtorWithArgs');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
====>Class_does_not_exist
{closure}(Class_does_not_exist)
object(WithCtorWithArgs)#%d (0) {
}
-===DONE===
dump_methodModifierNames('y');
?>
-==DONE==
--EXPECT--
string(1) "a"
array(0) {
[1]=>
string(9) "protected"
}
-==DONE==
$test = $obj instanceof ReflectionExtension;
var_dump($test);
?>
-==DONE==
--EXPECT--
bool(true)
-==DONE==
?>
-==DONE==
--EXPECTF--
Ok - ReflectionExtension::__construct() expects exactly %d parameter, %d given
Ok - ReflectionExtension::__construct() expects exactly %d parameter, %d given
Ok - ReflectionExtension::__construct() expects parameter 1 to be string, array given
-==DONE==
$test = ob_get_clean();
var_dump(empty($test));
?>
-==DONE==
--EXPECTF--
Deprecated: Function ReflectionExtension::export() is deprecated in %s on line %d
bool(false)
-==DONE==
$standard = new ReflectionExtension('standard');
var_dump($standard->getClassNames());
?>
-==DONE==
--EXPECTF--
array(4) {
[0]=>
[3]=>
%s(14) "AssertionError"
}
-==DONE==
$extension = new ReflectionExtension('ctype');
var_dump($extension->getClassNames());
?>
-==DONE==
--EXPECT--
array(0) {
}
-==DONE==
$ext = new ReflectionExtension('reflection');
var_dump($ext->getClasses());
?>
-==DONE==
--EXPECT--
array(17) {
["ReflectionException"]=>
string(19) "ReflectionReference"
}
}
-==DONE==
$dom = new ReflectionExtension('dom');
var_dump($dom->getDependencies());
?>
-==DONE==
--EXPECTF--
array(2) {
["libxml"]=>
["domxml"]=>
%s(9) "Conflicts"
}
-==DONE==
$standard = new ReflectionExtension('standard');
var_dump($standard->getDependencies());
?>
-==DONE==
--EXPECTF--
array(1) {
["session"]=>
%s(8) "Optional"
}
-==DONE==
$obj = new ReflectionExtension('reflection');
var_dump($obj->getName());
?>
-==DONE==
--EXPECT--
string(10) "Reflection"
-==DONE==
$test = floatval($var) == $var ? true : false;
var_dump($test);
?>
-==DONE==
--EXPECT--
bool(true)
-==DONE==
var_dump($testa);
var_dump(strlen($testb) > 24);
?>
-==DONE==
--EXPECT--
NULL
bool(true)
-==DONE==
$obj = new ReflectionExtension('reflection');
var_dump($obj->isPersistent());
?>
-==DONE==
--EXPECT--
bool(true)
-==DONE==
$obj = new ReflectionExtension('reflection');
var_dump($obj->isTemporary());
?>
-==DONE==
--EXPECT--
bool(false)
-==DONE==
$closure( 'succeeded' );
?>
-===DONE===
--EXPECT--
*** Testing ReflectionFunction::getClosure() : basic functionality ***
string(19) "Inside foo function"
string(16) "Arg is succeeded"
-===DONE===
$closure();
?>
-===DONE===
--EXPECT--
*** Testing ReflectionMethod::getClosure() : basic functionality ***
string(34) "Static Example class, Hello World!"
string(22) "Example class, bar: 42"
string(22) "Example class, bar: 34"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing ReflectionMethod::getClosure() : error conditions ***
-- Testing ReflectionMethod::getClosure() function with invalid object --
string(72) "Given object is not an instance of the class this method was declared in"
-===DONE===
}
}
?>
-==DONE==
--EXPECT--
bool(false)
bool(true)
string(9) "self::bar"
string(9) "Foo2::bar"
string(12) "CONST_TEST_1"
-==DONE==
echo new ReflectionParameter('ReflectionParameterTest', $key), "\n";
}
?>
-==DONE==
--EXPECTF--
Parameter #0 [ <required> $test ]
Parameter #1 [ <optional> $test2 = NULL ]
-==DONE==
echo $value->getDeclaringFunction() . "\n";
}
?>
-==DONE==
--EXPECTF--
Function [ <user> function ReflectionParameterTest ] {
@@ %s.php %d - %d
}
}
-==DONE==
var_dump($value->getPosition());
}
?>
-==DONE==
--EXPECT--
int(0)
int(1)
-==DONE==
var_dump($prop1->isDefault());
var_dump($prop2->isDefault());
?>
-==DONE==
--EXPECT--
bool(true)
bool(false)
bool(false)
bool(true)
bool(false)
-==DONE==
echo $value->__toString() . "\n";
}
?>
-==DONE==
--EXPECT--
Parameter #0 [ <required> $test ]
Parameter #1 [ <optional> $test2 = NULL ]
Parameter #2 [ <optional> ...$test3 ]
-==DONE==
var_dump($class->getName());
?>
-===DONE===
--EXPECT--
string(3) "Foo"
-===DONE===
$o->bla();
?>
-===DONE===
--EXPECT--
int(1)
bool(false)
bool(false)
Hello
-===DONE===
$r->setValue(3);
var_dump($r->getValue());
?>
-===DONE===
--EXPECT--
int(1)
int(2)
int(3)
-===DONE===
$foo = new Foo;
$foo->testBAR();
?>
-===DONE===
--EXPECT--
string(7) "testBAR"
string(7) "testBAR"
-===DONE===
var_dump($class->getStaticProperties());
?>
-===DONE===
--EXPECT--
array(1) {
["a"]=>
string(4) "test"
}
-===DONE===
var_dump($arr_static_vars);
?>
-===DONE===
--EXPECT--
string(4) "test"
array(1) {
bool(true)
}
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
Caught: Cannot access non-public member TestClass::$p
-===DONE===
echo new ReflectionFunction('foo'), "\n";
echo new ReflectionMethod('bar', 'foo'), "\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Function [ <user> function foo ] {
@@ %sbug41061.php 3 - 4
@@ %sbug41061.php 7 - 8
}
-===DONE===
new bar;
?>
-===DONE===
--EXPECTF--
object(ReflectionProperty)#%d (2) {
["name"]=>
int(2)
bool(false)
bool(true)
-===DONE===
new test;
?>
-===DONE===
--EXPECTF--
object(ReflectionProperty)#%d (2) {
["name"]=>
string(4) "test"
}
}
-===DONE===
var_dump(strip_doc_comment($rb->getDocComment()));
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
-===DONE===
require __DIR__ . '/bug74454.inc';
}
?>
-===DONE===
--EXPECT--
ParseError: syntax error, unexpected 'if' (T_IF), expecting function (T_FUNCTION) or const (T_CONST)
-===DONE===
var_dump($rp->isOptional());
?>
-===DONE===
--EXPECT--
int(2)
int(1)
bool(true)
bool(false)
bool(true)
-===DONE===
var_dump($rp->isOptional());
?>
-===DONE===
--EXPECT--
string(8) "__invoke"
int(2)
int(1)
bool(false)
bool(true)
-===DONE===
echo $method->getName ()."\n";
?>
-===DONE===
--EXPECT--
__invoke
__invoke
-===DONE===
echo $method->getName ()."\n";
?>
-===DONE===
--EXPECT--
{closure}
{closure}
-===DONE===
$closure2->__invoke ();
?>
-===DONE===
--EXPECT--
Invoked!
Invoked!
Invoked!
Invoked!
Invoked!
-===DONE===
}
?>
-===DONE===
--EXPECT--
int(2)
int(1)
bool(false)
bool(true)
string(54) "The parameter specified by its name could not be found"
-===DONE===
check_params(new ReflectionMethod('test::method'));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
#####test()#####
===0===
isOptional: bool(true)
isDefaultValueAvailable: bool(true)
getDefaultValue: string(6) "FooBar"
-===DONE===
var_dump(property_exists(new A, 'init'));
var_dump(property_exists(new A, 'empty'));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
===A===
obj(A)::$a
bool(false)
bool(true)
bool(true)
-===DONE===
var_dump(session_cache_limiter());
var_dump(session_cache_expire());
?>
-===DONE===
--EXPECT--
string(9) "PHPSESSID"
string(3) "foo"
string(0) ""
string(7) "nocache"
int(180)
-===DONE===
var_dump($r->getNumberOfParameters());
var_dump($r->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(0)
-===DONE===
ob_end_flush();
?>
-==DONE==
--EXPECT--
bool(true)
-==DONE==
<p><a href="index.php#place">External link with anchor</a></p>
<p><a href="http://php.net#foo">External link with anchor 2</a></p>
<p><a href="#place">Internal link</a></p>
-===DONE===
--EXPECT--
<p><a href="index.php?PHPSESSID=sessionidhere">Click This Anchor Tag!</a></p>
<p><a href="index.php?PHPSESSID=sessionidhere#place">External link with anchor</a></p>
<p><a href="http://php.net?PHPSESSID=sessionidhere#foo">External link with anchor 2</a></p>
<p><a href="#place">Internal link</a></p>
-===DONE===
var_dump(session_cache_limiter());
var_dump(session_save_path());
?>
-===DONE===
--EXPECT--
int(180)
string(7) "nocache"
string(0) ""
-===DONE===
session_id('BUG74941');
var_dump(session_start());
?>
-===DONE===
--EXPECT--
.
bool(true)
-===DONE===
test('sxe->elem22["attr22"]');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
===sxe
bool(true)
bool(false)
bool(false)
NULL
-===DONE===
var_dump(simplexml_load_file(__DIR__.'/sxe私はガラスを食べられます.xml'));
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (2) {
["@attributes"]=>
}
}
}
-===DONE===
var_dump(simplexml_load_file(__DIR__.'/sxe.xml'));
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (2) {
["@attributes"]=>
}
}
}
-===DONE===
var_dump($copy);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (2) {
["@attributes"]=>
}
}
}
-===DONE===
var_dump(simplexml_load_string($xml));
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (2) {
["@attributes"]=>
}
}
}
-===DONE===
var_dump(trim((string)$elem2));
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (2) {
["@attributes"]=>
}
}
string(11) "CDATA block"
-===DONE===
}
?>
-===DONE===
--EXPECT--
string(5) "elem1"
string(10) "Bla bla 1."
===COMMENT===
string(5) "elem1"
string(10) "Bla bla 1."
-===DONE===
$dummy = $sxe->elem1[$a];
var_dump($a);
?>
-===Done===
--EXPECTF--
===Property===
object(SimpleXMLElement)#%d (3) {
===Misc.===
int(4)
int(4)
-===Done===
var_dump(trim($val));
}
?>
-===DONE===
--EXPECT--
string(5) "elem1"
string(16) "SimpleXMLElement"
string(6) "elem11"
string(16) "SimpleXMLElement"
string(10) "Bla bla 2."
-===DONE===
);
var_dump($sxe->children());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(SimpleXMLElement)#%d (3) {
["@attributes"]=>
["elem11"]=>
string(10) "Bla bla 2."
}
-===DONE===
var_dump(simplexml_load_string($xml, 'simplexml_inherited'));
?>
-===DONE===
--EXPECTF--
object(simplexml_inherited)#%d (2) {
["@attributes"]=>
}
}
}
-===DONE===
print $sxe->baz[1];
echo "\n";
?>
-===DONE===
--EXPECT--
===BAR===
bar
baz1
===BAZ1===
baz2
-===DONE===
var_dump((string)$sxe);
?>
-===DONE===
--EXPECT--
string(6) "barbar"
-===DONE===
$people->person['age'] += 5;
var_dump($people->person['age']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
[0]=>
string(2) "35"
}
-===DONE===
$people->person['age'] += 5;
var_dump($people->person[0]['age']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
[0]=>
string(1) "5"
}
-===DONE===
$people->person[1]['age'] += 5;
var_dump($people->person[1]['age']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
[0]=>
string(1) "5"
}
-===DONE===
var_dump($people->person[0]['name']);
var_dump($people->person[1]['name']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
[0]=>
string(3) "Boe"
}
-===DONE===
var_dump($people->person[0]['name']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
[0]=>
string(9) "JoeFooBar"
}
-===DONE===
var_dump($people->person['name']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
[0]=>
string(6) "FooBar"
}
-===DONE===
echo "---22---\n";
print_xml2(simplexml_load_string($xml1));
?>
-===DONE===
--EXPECT--
---11---
person: Joe
---22---
person: Joe
child: Ann
-===DONE===
}
?>
-===DONE===
--EXPECT--
string(5) "elem1"
string(10) "Bla bla 1."
===COMMENT===
string(5) "elem2"
string(28) "Here we have some text data."
-===DONE===
print "Error\n";
}
?>
-===DONE===
--EXPECT--
foo
Works
-===DONE===
print "Error\n";
}
?>
-===DONE===
--EXPECT--
Works
-===DONE===
}
?>
-===DONE===
--EXPECTF--
===CONTENT===
object(SimpleXMLElement)#%d (1) {
[0]=>
string(11) "slide_*.xml"
}
-===DONE===
var_dump($sxe);
var_dump($sxe['attr']);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
["@attributes"]=>
[0]=>
string(%d) "foo%sbar%sbaz"
}
-===DONE===
test('elem[2]/@attr2');
?>
-===DONE===
--EXPECTF--
===elem/@attr2===
array(3) {
}
}
}
-===DONE===
var_dump($sxe->getDocNamespaces());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(1) {
["xhtml"]=>
}
array(0) {
}
-===DONE===
traverse_xml($people);
?>
-===DONE===
--EXPECT--
<people>
<person>Jane
</person>
</people>
-===DONE===
$people->person[3]['gender'] = 'error';
traverse_xml($people);
?>
-===DONE===
--EXPECTF--
<people>
</people>
<person gender="error">
</person>
</people>
-===DONE===
traverse_xml($people);
?>
-===DONE===
--EXPECT--
<people>
</people>
<person name="John">
</person>
</people>
-===DONE===
}
?>
-===DONE===
--EXPECT--
string(3) "Joe"
int(3)
string(4) "Jane"
int(3)
int(0)
-===DONE===
var_dump(isset($atts[TRUE]));
?>
-===DONE===
--EXPECT--
test
test 2
bool(true)
bool(false)
bool(false)
-===DONE===
echo $sxe->asXML();
?>
-===DONE===
--EXPECTF--
Warning: SimpleXMLElement::addAttribute(): Attribute already exists in %s031.php on line %d
<child1>test 2</child1>
<s:child3/>
<s:test1>myval</s:test1><m:test2 xmlns:m="urn::testnew">myval</m:test2><test3 xmlns="urn::testnew">myval</test3><test4>myval</test4><test5>myval</test5></root>
-===DONE===
var_dump($people2 == $people1);
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
bool(false)
-===DONE===
var_dump((object)$people);
?>
-===DONE===
--EXPECTF--
bool(false)
bool(true)
}
}
}
-===DONE===
echo $p->__toString()."\n";
echo $p."\n";
?>
-==Done==
--EXPECT--
Blah 1
Blah 1
Blah 1
-==Done==
$sxe = new SXE($str);
var_dump(count($sxe));
?>
-==Done==
--EXPECT--
Called Count!
int(2)
-==Done==
$sxe = new SimpleXmlElement($str);
var_dump($sxe instanceof Countable);
?>
-==Done==
--EXPECT--
bool(true)
-==Done==
}
?>
-===DONE===
--EXPECT--
drink is Cola
drink is Juice
drink is Coffee
drink is Tea
-===DONE===
$xml->bla->posts[]->name = "FooBar";
echo $xml->asXML();
?>
-===DONE===
-<?php exit(0); __halt_compiler(); ?>
--EXPECT--
<?xml version="1.0"?>
<root><bla><posts><name>FooBar</name></posts></bla></root>
<root><bla><posts><name>FooBar</name></posts></bla></root>
<?xml version="1.0"?>
<root><bla><posts><name>FooBar</name></posts></bla></root>
-===DONE===
var_dump($val);
?>
-===DONE===
--EXPECT--
int(1)
int(1)
-===DONE===
$xml->foo .= "bar";
print $xml->asXML();
?>
-===DONE===
--EXPECT--
<?xml version="1.0"?>
<root><foo>foobar</foo></root>
-===DONE===
$xml->{""} .= "bar";
print $xml->asXML();
?>
-===DONE===
--EXPECTF--
Warning: main(): Cannot write or create unnamed element in %s on line %d
Warning: main(): Cannot write or create unnamed element in %s on line %d
<?xml version="1.0"?>
<root><foo/></root>
-===DONE===
}
?>
-===DONE===
--EXPECT--
Error: simplexml_load_string() expects parameter 2 to be a class name derived from SimpleXMLElement, 'Setting' given
Error: simplexml_load_file() expects parameter 2 to be a class name derived from SimpleXMLElement, 'Setting' given
-===DONE===
$add->Host->addAttribute('enable', 'true');
?>
-===DONE===
--EXPECTF--
Warning: SimpleXMLElement::addAttribute(): Unable to locate parent Element in %s on line %d
-===DONE===
echo $xml->asXML();
?>
-===DONE===
--EXPECT--
<?xml version="1.0"?>
<img src="foo" alt=""/>
-===DONE===
echo($xml->asXml());
?>
-===DONE===
--EXPECT--
<?xml version="1.0" standalone="yes"?>
<collection><movie><characters><character><name>Miss Coder</name></character></characters></movie></collection>
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
root(recursive): 'root' -- namespaces: #ns1, #ns2, #ns3
root(non-recursive): 'root' -- namespaces:
children(#ns1): 'node1' -- namespaces: #ns1
children(#ns2): 'node2' -- namespaces: #ns2
children(#ns3): 'node3' -- namespaces: #ns3
-===DONE===
echo $a->b->getName()."\n";
echo $a->b->c->getName()."\n";
?>
-===DONE===
--EXPECT--
a
b
c
-===DONE===
echo $gchild[0]."\n";
}
?>
-===DONE===
--EXPECT--
hello
-===DONE===
echo count($ancestry) . ' steps: ' . $path . PHP_EOL;
}
?>
-===DONE===
--EXPECT--
3 steps: xml/fieldset1/field1
3 steps: xml/fieldset1/field2
4 steps: xml/fieldset2/options/option3
3 steps: xml/fieldset2/field1
3 steps: xml/fieldset2/field2
-===DONE===
}
?>
-===DONE===
--EXPECT--
explicit conversion
no conversion
-===DONE===
$n->addAttribute("foo:e", "f", "http://bar.com");
print_r($xml->asXml());
?>
-===DONE===
--EXPECTF--
Warning: SimpleXMLElement::addAttribute(): Attribute requires prefix for namespace in %sbug43221.php on line %d
<?xml version="1.0" encoding="utf-8"?>
<root><node xmlns:foo="http://bar.com" a="b" foo:e="f">value</node></root>
-===DONE===
print $xml_element->asXML();
?>
-===DONE===
--EXPECT--
a & b
a & b
a & b
<?xml version="1.0"?>
<root><node1>a &#38; b</node1><node2>a & b</node2></root>
-===DONE===
$atts = $x->xpath("/xml/data/@label");
echo $atts[0] . "\n";
?>
-===DONE===
--EXPECT--
I am A
I am a:Nothing
I am a:A
I am a:Nothing
I am Nothing
-===DONE===
var_dump(isset($x->o->text));
var_dump(isset($x->o->xx));
?>
-===DONE===
--EXPECT--
bool(true)
bool(false)
bool(false)
bool(false)
bool(true)
-===DONE===
$xml = new SimpleXMLElement('<foo><bar/><baz/></foo>');
print_r($xml);
?>
-===DONE===
--EXPECT--
SimpleXMLElement Object
(
)
)
-===DONE===
$obj = simplexml_load_string($xml);
print_r(get_object_vars($obj));
?>
-===DONE===
--EXPECT--
Array
(
[key] => value
)
-===DONE===
<?php
var_dump(simplexml_load_string('<test1><test2> </test2><test3></test3></test1>'));
?>
-===DONE===
--EXPECT--
object(SimpleXMLElement)#1 (2) {
["test2"]=>
object(SimpleXMLElement)#3 (0) {
}
}
-===DONE===
$sxe->bar = '';
echo $sxe->asXML();
?>
-===DONE===
--EXPECT--
<?xml version="1.0"?>
<foo><bar/></foo>
<?xml version="1.0"?>
<foo><bar/></foo>
-===DONE===
var_dump( $x->person[1]->getDocNamespaces(false, false) );
?>
-===DONE===
--EXPECT--
getDocNamespaces
}
array(0) {
}
-===DONE===
var_dump((string)$root->children('special-ns')->child);
var_dump($root->child);
?>
-===DONE===
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
[0]=>
string(5) "World"
object(SimpleXMLElement)#%d (0) {
}
-===DONE===
var_dump($sxe->Body->children('')->businessList);
?>
-===DONE===
--EXPECTF--
array(1) {
["soap"]=>
}
}
}
-===DONE===
var_dump($sxe->Body->children('')->businessList);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(SimpleXMLElement)#%d (1) {
["Body"]=>
}
}
}
-===DONE===
var_dump(simplexml_load_string($xml, 'SimpleXMLIterator'));
?>
-===DONE===
--EXPECTF--
object(SimpleXMLIterator)#%d (2) {
["@attributes"]=>
}
}
}
-===DONE===
var_dump(trim($sxe->elem1));
?>
-===DONE===
--EXPECT--
string(5) "elem1"
string(17) "SimpleXMLIterator"
===DUMP===
string(17) "SimpleXMLIterator"
string(10) "Bla bla 1."
-===DONE===
}
?>
-===DONE===
--EXPECTF--
Warning: Invalid argument supplied for foreach() in %ssxe_003.php on line %d
===RESET===
string(7) "elem111"
string(17) "SimpleXMLIterator"
string(7) "Foo Bar"
-===DONE===
}
?>
-===DONE===
--EXPECT--
SXETest::rewind
SXETest::valid
SXETest::next
SXETest::valid
SXETest::valid
-===DONE===
var_dump(count($sxe->elem2));
?>
-===DONE===
--EXPECT--
SXETest::count
int(3)
int(1)
SXETest::count
int(2)
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Method [ <internal:snmp, ctor> public method __construct ] {
- Parameters [0] {
}
}
-===DONE===
}
?>
-==DONE==
--CLEAN--
<?php
unlink(__DIR__ . DIRECTORY_SEPARATOR . "bug73037_server.php");
Function 'CATALOG' doesn't exist
-==DONE==
$soap->call(1.1);
echo $soap->__getLastRequest();
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://localhost/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Body><ns1:call><param0 xsi:type="xsd:float">1.1</param0></ns1:call></SOAP-ENV:Body></SOAP-ENV:Envelope>
-===DONE===
else
printf("Content-Type Default OK" . PHP_EOL);
?>
-==DONE==
--EXPECT--
Content-Type OK
Content-Type Default OK
-==DONE==
print_r($data);
}
?>
-===DONE===
--EXPECT--
Array
(
[0] => \\\line1
line2\\\
)
-===DONE===
echo '$list = ';var_export($res);echo ";\n";
?>
-===DONE===
-<?php exit(0); ?>
--CLEAN--
<?php
$file = __DIR__ . '/SplFileObject_fputcsv.csv';
18 => '"\\"","aaa"',
19 => '"\\""",aaa',
);
-===DONE===
echo $line;
}
?>
-===DONE===
--EXPECT--
\
"\"""
-===DONE===
$file->setCsvControl(',', '"', '');
var_dump($file->getCsvControl());
?>
-===DONE===
--EXPECT--
array(3) {
[0]=>
[2]=>
string(0) ""
}
-===DONE===
var_dump($s3[$o1] === $s3[$o2]);
?>
-===DONE===
--EXPECT--
some_value
caught
object(stdClass)#2 (0) {
}
bool(true)
-===DONE===
var_dump($ao2->asort(SORT_NUMERIC));
var_dump($ao2);
?>
-===DONE===
--EXPECTF--
*** Testing ArrayObject::asort() : basic functionality ***
bool(true)
int(4)
}
}
-===DONE===
var_dump($ao1->asort());
var_dump($ao1, $c);
?>
-===DONE===
--EXPECT--
*** Testing ArrayObject::asort() : basic functionality ***
bool(true)
["prop2"]=>
string(1) "z"
}
-===DONE===
var_dump($ao2->ksort(SORT_STRING));
var_dump($ao2);
?>
-===DONE===
--EXPECTF--
*** Testing ArrayObject::ksort() : basic functionality ***
bool(true)
int(3)
}
}
-===DONE===
var_dump($ao1->ksort());
var_dump($ao1, $c);
?>
-===DONE===
--EXPECT--
*** Testing ArrayObject::ksort() : basic functionality ***
bool(true)
["z"]=>
string(5) "prop2"
}
-===DONE===
var_dump($ao2->natcasesort('blah'));
var_dump($ao2);
?>
-===DONE===
--EXPECT--
*** Testing ArrayObject::natcasesort() : basic functionality ***
bool(true)
string(5) "boo22"
}
}
-===DONE===
var_dump($ao2->natsort('blah'));
var_dump($ao2);
?>
-===DONE===
--EXPECT--
*** Testing ArrayObject::natsort() : basic functionality ***
bool(true)
string(5) "boo22"
}
}
-===DONE===
$ao->uasort('cmp');
var_dump($ao);
?>
-===DONE===
--EXPECT--
*** Testing ArrayObject::uasort() : basic functionality ***
object(ArrayObject)#1 (1) {
int(1)
}
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
Function expects exactly one argument
Function expects exactly one argument
-===DONE===
$ao->uksort('cmp');
var_dump($ao);
?>
-===DONE===
--EXPECT--
*** Testing ArrayObject::uksort() : basic functionality ***
object(ArrayObject)#1 (1) {
int(4)
}
}
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
Function expects exactly one argument
Function expects exactly one argument
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(ArrayObject)#%d (1) {
["storage":"ArrayObject":private]=>
int(4)
}
}
-===DONE===
var_dump($arrayObject);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(ArrayObject)#%d (1) {
["storage":"ArrayObject":private]=>
}
}
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
test Object
(
pub => public
imp => implicit
dyn => dynamic
-===DONE===
echo $student, "\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
01234123, Joe
00000014, Bob
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
==Normal==
0=>0 - 0=>0
0=>0 - 1=>1
0=>0 - 2=>2
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
test Object
(
pub => public
imp => implicit
dyn => dynamic
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
0=>modify - 0=>modify
0=>modify - 1=>1
2=>2 - 0=>modify
2=>2 - 1=>1
2=>2 - 2=>2
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1
21
222
231
3
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1
21
222
231
3
-===DONE===
var_dump($obj->getArrayCopy());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
array(4) {
[0]=>
[6]=>
string(9) "changed 6"
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(2) {
[0]=>
[1]=>
int(3)
}
-===DONE===
var_dump($it->count());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===Array===
int(3)
two=>2
int(3)
int(3)
-===DONE===
?>
===DONE===
-<?php exit(0); ?>
--EXPECTF--
===Array===
0=>zero
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(11)
int(5)
int(8)
int(9)
int(10)
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(ArrayObject)#%d (1) {
%s"storage"%s"ArrayObject":private]=>
int(4)
}
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(0)
int(1)
int(1)
int(2)
int(3)
-===DONE===
check($obj, 1);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
ArrayObjectEx::__construct()
===CHECK===
ArrayIteratorEx::setFlags(3)
int(1)
bool(true)
-===DONE===
?>
===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(1)
int(2)
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
ArrayIteratorEx::rewind
ArrayIteratorEx::valid
int(2)
ArrayIteratorEx::next
ArrayIteratorEx::valid
-===DONE===
}
?>
-===DONE===
--EXPECT--
foo::seek(bar)
got exception
-===DONE===
var_dump($b);
?>
-===DONE===
--EXPECTF--
==ArrayObject===
object(MyArrayObject)#%d (1) {
["baz"]=>
string(3) "Foo"
}
-===DONE===
var_dump($array->offsetExists('nokey'));
?>
-===DONE===
--EXPECT--
bool(true)
bool(false)
-===DONE===
print_R($foo);
?>
-===DONE===
--EXPECT--
FooBar::offsetSet(0, 0)
FooBar::offsetSet(1, 1)
)
)
-===DONE===
var_dump($myArray['two']);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
myArray::offsetSet(one,one)
myArray::offsetGet(one)
myArray::offsetSet(two,two)
myArray::offsetGet(two)
string(3) "two"
-===DONE===
var_dump(count($arrayObj));
?>
-===DONE===
-<?php //exit(0); ?>
--EXPECT--
Initiate Obj
Assign values
)
int(3)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
string(%d) "%s"
string(%d) "%s"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
First
string(%d) "%s"
string(%d) "%s"
Second
string(%d) "%s"
-===DONE===
}
?>
-===DONE===
--EXPECT--
foo::offsetGet(bar)
got exception
-===DONE===
$b[0] = 3;
var_dump($a[0], $b[0]);
?>
-===DONE===
--EXPECT--
===ArrayObject===
int(1)
int(2)
int(3)
int(3)
-===DONE===
}
?>
-===DONE===
--EXPECT--
Collection::__construct
Collection::rewind
Collection::key
TestFilter::accept
string(17) "Failure in Accept"
-===DONE===
test_array($array, 'Public Property New', RecursiveArrayIterator::CHILD_ARRAYS_ONLY);
test_array($array, 'Protected Property New', RecursiveArrayIterator::CHILD_ARRAYS_ONLY);
?>
-===DONE===
-<?php exit(0); ?>
-?>
-===DONE===
--EXPECT--
===Default with array===
1 => apple
===Protected Property New===
1 => apple
1 => grape
-===DONE===
echo "View::baz empty\n";
}
?>
-===DONE===
--EXPECT--
View::foo empty
View::bar empty
View::baz empty
-===DONE===
print_r(spl_autoload_functions());
?>
-===DONE===
--EXPECT--
Array
(
)
)
-===DONE===
$a->offsetSet('property', 0);
var_dump($a->offsetExists('property'));
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump($projects->offsetExists(1));
var_dump($projects->offsetExists('2'));
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
echo "Found $count entries!\n";
}
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__ . '/bug42364/test');
?>
--EXPECTF--
Found %i entries!
-===DONE===
var_dump($info->getRealPath());
var_dump($info->getPathInfo()->getRealPath());
?>
-===DONE===
--EXPECTF--
string(%d) "%stests%sbug48361.php"
string(%d) "%stests"
-===DONE===
echo $ss."\n";
var_dump(unserialize($ss));
?>
-===DONE===
--EXPECTF--
O:16:"SplObjectStorage":2:{i:0;a:4:{i:0;O:8:"stdClass":0:{}i:1;a:2:{s:4:"prev";i:2;s:4:"next";O:8:"stdClass":0:{}}i:2;r:6;i:3;a:1:{s:4:"prev";r:3;}}i:1;a:0:{}}
object(SplObjectStorage)#2 (1) {
}
}
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
a
b
c
Parameter offset must be >= 0
-===DONE===
print var_dump($file->bam); // is null or UNKNOWN:0
?>
-===DONE===
--EXPECT--
array(0) {
}
-===DONE===
var_dump($params);
?>
-===DONE===
--EXPECTF--
array(3) {
[0]=>
string(6) "escape"
}
}
-===DONE===
var_dump((bool) $o);
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
$regex->getPregFlags()
);
?>
-===DONE===
--EXPECT--
int(0)
int(0)
int(0)
-===DONE===
var_dump($params);
?>
-===DONE===
--EXPECT--
array(4) {
[0]=>
string(6) "escape"
}
}
-===DONE===
}
}
?>
-===DONE===
--EXPECTF--
string(%d) "%s%eext%espl%etests%ebug68825.php"
-===DONE===
--CLEAN--
<?php
$dir = __DIR__ . '/bug68825';
var_dump($data);
?>
-===DONE===
--EXPECTF--
array(2) {
[0]=>
array(0) {
}
}
-===DONE===
var_dump($data);
?>
-===DONE===
--EXPECTF--
array(2) {
[0]=>
[1]=>
int(1)
}
-===DONE===
var_dump($data);
?>
-===DONE===
--EXPECTF--
array(2) {
[0]=>
[1]=>
int(1)
}
-===DONE===
var_dump($y[NULL]);
var_dump($y[NULL]++);
?>
-===DONE===
--EXPECTF--
Notice: Undefined index: in %s on line %d
NULL
Notice: Undefined index: in %s on line %d
NULL
-===DONE===
print $e->getMessage()."\n";
}
?>
-===DONE===
--EXPECT--
Offset invalid or out of range
-===DONE===
echo 'expected exception: ' . $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
expected exception: Iterators' LIFO/FIFO modes for SplStack/SplQueue objects are frozen
-===DONE===
$iterator->next();
}
?>
-===DONE===
--EXPECT--
2
3
4
5
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing class_implements() : basic ***
array(1) {
["foo"]=>
string(3) "foo"
}
-===DONE===
var_dump($arr);
}
?>
-===DONE===
--EXPECT--
*** Testing class_implements() : basic ***
array(2) {
["foo"]=>
string(3) "foo"
}
-===DONE===
var_dump(class_implements('non_existent2', false));
?>
-===DONE===
--EXPECTF--
*** Testing class_implements() : variation ***
--- testing no interfaces ---
Warning: class_implements(): Class non_existent2 does not exist in %s on line %d
bool(false)
-===DONE===
fclose($res);
?>
-===DONE===
--EXPECTF--
*** Testing class_implements() : variation ***
--resource--
Error: 2 - class_implements(): object or string expected, %s(%d)
bool(false)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing class_uses() : basic ***
array(1) {
["foo"]=>
string(3) "foo"
}
-===DONE===
var_dump($arr);
}
?>
-===DONE===
--EXPECT--
*** Testing class_uses() : basic ***
array(2) {
}
array(0) {
}
-===DONE===
var_dump(class_uses('non_existent2', false));
?>
-===DONE===
--EXPECTF--
*** Testing class_uses() : variation ***
--- testing no traits ---
Warning: class_uses(): Class non_existent2 does not exist in %s on line %d
bool(false)
-===DONE===
fclose($res);
?>
-===DONE===
--EXPECTF--
*** Testing class_uses() : variation ***
--resource--
Error: 2 - class_uses(): object or string expected, %s(%d)
bool(false)
-===DONE===
preg_match('/x/', $d);
var_dump(is_string($d));
?>
-===DONE===
--EXPECTF--
object(DirectoryIterator)#%d (4) {
%s"pathName"%s"SplFileInfo":private]=>
}
bool(false)
bool(false)
-===DONE===
preg_match('/x/', $d);
var_dump(is_string($d));
?>
-===DONE===
--EXPECTF--
object(DirectoryIterator)#%d (3) {
%s"pathName"%s"SplFileInfo":private]=>
}
bool(false)
bool(false)
-===DONE===
}
}
?>
-===DONE===
--EXPECTF--
===DirectoryIterator===
DirectoryIterator
GlobIterator
int(32)
bool(true)
-===DONE===
}
var_dump($count > 0);
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump((string)$c == (string)$a);
var_dump($a->key(), $c->key());
?>
-===DONE===
--EXPECT--
bool(true)
int(0)
bool(true)
int(3)
int(3)
-===DONE===
var_dump((string)$c == (string)$a);
var_dump($a->key() == $c->key());
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump($n !== $m, $m === $o, $p === 0);
?>
-===DONE===
--EXPECTF--
With seek(2) we get %d
With seek(0) we get %d
bool(true)
bool(true)
bool(true)
-===DONE===
$dll_clone->pop();
echo count($dll)."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Can't pop from an empty datastructure
Exception: Can't shift from an empty datastructure
NULL
NULL
1
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
0=>2
->0=>2
popped 4
1=>3
popped 3
-===DONE===
var_dump($dll->count());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
2=>4
1=>3
0=>3
0=>4
int(0)
-===DONE===
$stack_clone->pop();
echo count($stack)."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Can't pop from an empty datastructure
Exception: Can't shift from an empty datastructure
NULL
NULL
3
-===DONE===
$queue_clone->dequeue();
echo count($queue)."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Can't shift from an empty datastructure
Exception: Can't shift from an empty datastructure
int(1)
int(2)
3
-===DONE===
echo "Exception: ".$e->getMessage()."\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(1)
int(2)
Exception: Offset invalid or out of range
int(1)
Exception: Offset invalid or out of range
-===DONE===
var_dump($a->current(), $a->next());
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(1)
NULL
NULL
int(3)
NULL
-===DONE===
var_dump($dll->current());
?>
-===DONE===
--EXPECT--
NULL
int(1)
int(2)
int(4)
int(3)
-===DONE===
$dll->prev();
var_dump($dll->current());
?>
-===DONE===
--EXPECT--
NULL
-===DONE===
var_dump($a);
?>
-===DONE===
--EXPECTF--
object(SplDoublyLinkedList)#%d (2) {
["flags":"SplDoublyLinkedList":private]=>
*RECURSION*
}
}
-===DONE===
echo $dll->pop()."\n";
echo $dll->pop()."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Offset invalid or out of range
7
3
2
1
-===DONE===
echo $dll->current()."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1
3
-===DONE===
test(array(1,array(21,22),3), array(1,array(21,"22"),3), true);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
bool(true)
bool(false)
bool(false)
bool(true)
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
int(0)
string(%d) "0
string(1) "4"
int(5)
string(1) "5"
-===DONE===
test('fileobject_001b.txt');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===fileobject_001a.txt===
int(0)
bool(true)
int(5)
bool(true)
-===DONE===
test(__DIR__, substr(__DIR__,-1), 'l');
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
===0===
object(SplFileInfo)#%d (2) {
bool(true)
LogicException: Cannot use SplFileObject with directories
LogicException: Cannot use SplFileObject with directories
-===DONE===
var_dump($fo->getFilename());
var_dump($fo->getRealPath());
?>
-==DONE==
--EXPECTF--
string(%d) "%sspl%stests"
string(19) "fileobject_004.phpt"
string(%d) "%sspl%stests%sfileobject_004.phpt"
-==DONE==
$fo->fwrite("blahlubba");
?>
-==DONE==
--CLEAN--
<?php
$path = __DIR__.DIRECTORY_SEPARATOR.'fileobject_005.txt';
--EXPECTF--
bool(true)
string(4) "blah"
-==DONE==
$a[0] = "valueNew";
var_dump($b[0]);
?>
-===DONE===
--EXPECT--
Exception: Index invalid or out of range
Exception: Index invalid or out of range
int(10)
bool(true)
string(6) "value0"
-===DONE===
var_dump(count($a), $a->getSize(), count($a) == $a->getSize());
?>
-===DONE===
--EXPECT--
A::offsetSet
Exception: Index invalid or out of range
int(2)
int(10)
bool(false)
-===DONE===
echo "$k => $v\n";
}
?>
-===DONE===
--EXPECT--
==Direct instance==
0 => a
4 => f
A::next
A::valid
-===DONE===
}
?>
-===DONE===
--EXPECT--
string(29) "Index invalid or out of range"
-===DONE===
}
?>
-===DONE===
--EXPECT--
Ok - SplFixedArray::__construct() expects parameter 1 to be int, object given
Ok - SplFixedArray::__construct() expects parameter 1 to be int, string given
Ok - SplFixedArray::__construct() expects parameter 1 to be int, string given
-===DONE===
var_dump(empty($a["3"]));
?>
-==DONE==
--EXPECTF--
int(0)
int(0)
bool(false)
string(3) "foo"
bool(true)
-==DONE==
echo $h->extract()."\n";
echo $h2->extract()."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Can't extract from an empty heap
5
--
4
4
-===DONE===
echo $h->extract()."\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Can't extract from an empty heap
5
0
--
4
-===DONE===
echo $out."\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
10
9
2
1
0
-===DONE===
echo "Exception: ".$e->getMessage()."\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
inserted 1
Exception: foo
Recovering..
int(1)
int(2)
-===DONE===
echo "$k => $o\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
99 => 1
98 => 2
2 => 98
1 => 99
0 => 100
-===DONE===
echo "$k => $o\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
99 => 100
98 => 99
2 => 3
1 => 2
0 => 1
-===DONE===
$h->next();
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
count($h) = 4
$h->count() = 4
2=>4
1=>1
0=>0
-===DONE===
var_dump($h);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
object(SplMaxHeap)#1 (3) {
["flags":"SplHeap":private]=>
int(1)
}
}
-===DONE===
testForException( $heap );
?>
-==DONE==
--EXPECT--
An iterator cannot be used with foreach by reference
An iterator cannot be used with foreach by reference
An iterator cannot be used with foreach by reference
An iterator cannot be used with foreach by reference
An iterator cannot be used with foreach by reference
-==DONE==
$a->insert($a);
var_dump($a)
?>
-===DONE===
--EXPECTF--
object(SplMaxHeap)#%d (3) {
["flags":"SplHeap":private]=>
*RECURSION*
}
}
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
NumericArrayIterator::__construct
NumericArrayIterator::rewind
SeekableNumericArrayIterator::greaterThan(2)
NumericArrayIterator::current
4 is greater than 2
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1
21
222
231
3
-===DONE===
echo $it->__toString(), "\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
01234123, Joe
00000014, Bob
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
NumericArrayIterator::__construct
NumericArrayIterator::rewind
NumericArrayIterator::current
NumericArrayIterator::key
4
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
ArrayIteratorEx::rewind
int(0)
int(1)
int(2)
int(3)
-===DONE===
echo $child."\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Hello
World
-===DONE===
var_dump($v);
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===0===
ArrayIteratorEx::rewind
NoRewindIteratorEx::rewind
NoRewindIteratorEx::valid
ArrayIteratorEx::valid
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
ArrayIteratorEx::rewind
ArrayIteratorEx::valid
ArrayIteratorEx::current
ArrayIteratorEx::key
int(0)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
EmptyIteratorEx::rewind
EmptyIteratorEx::valid
-===DONE===
}
?>
-===DONE===
-<?php exit(0);
--EXPECT--
===EmptyIterator===
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===EmptyIterator===
===InfiniteIterator===
1=>B
2=>C
1=>B
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===Current===
0=>A
===Foreach===
1=>B
2=>C
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===Empty===
===Append===
1=>B
2=>C
3=>D
-===DONE===
echo "$k=>$v\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
RecursiveArrayIteratorIterator::rewind
RecursiveArrayIteratorIterator::valid
MyRecursiveArrayIterator::valid = false
RecursiveArrayIteratorIterator::valid
MyRecursiveArrayIterator::valid = false
-===DONE===
echo str_repeat(' ',$rit->getDepth()+1)."$k=>$v\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
<ul>
0=>a
</ul>
3=>d
<ul>
-===DONE===
echo str_repeat(' ',$rit->getDepth()+1)."$k=>$v\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Menu::getIterator
<ul>
</ul>
3=>d
<ul>
-===DONE===
}
?>
-===DONE===
-<?php exit(0);
--EXPECT--
===EmptyIterator===
===InfiniteIterator===
1=>B
2=>C
1=>B
-===DONE===
echo "$k=>$v\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
RecursiveArrayIteratorIterator::rewind
RecursiveArrayIteratorIterator::callHasChildren(0) = no/no
MyRecursiveArrayIterator::valid = false
RecursiveArrayIteratorIterator::valid
MyRecursiveArrayIterator::valid = false
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
RecursiveArrayIteratorIterator::rewind
RecursiveArrayIteratorIterator::callHasChildren(0) = no/no
RecursiveArrayIteratorIterator::callHasChildren(0) = yes/yes
RecursiveArrayIteratorIterator::callGetChildren(skip)
Objects returned by RecursiveIterator::getChildren() must implement RecursiveIterator
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
RecursiveArrayIteratorIterator::rewind
RecursiveArrayIteratorIterator::callHasChildren(0) = no/no
MyRecursiveArrayIterator::valid = false
RecursiveArrayIteratorIterator::valid
MyRecursiveArrayIterator::valid = false
-===DONE===
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1
2
32
331
4
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
MyRecursiveIteratorIterator::beginIteration()
1
331
4
MyRecursiveIteratorIterator::endIteration()
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
0=>1
hasNext: yes
hasNext: no
3=>4
hasNext: no
-===DONE===
var_dump(isset($it[3])); // deleted
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
0=>1
1=>2
bool(false)
bool(false)
bool(false)
-===DONE===
}
var_dump($it->getMaxDepth());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===?===
bool(false)
bool(false)
string(33) "Parameter max_depth must be >= -1"
int(4)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1=>123
2=>123
24=>22
a2d=>7
25=>42
-===DONE===
var_dump($it->valid());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
bool(false)
bool(false)
Accessing the key of an EmptyIterator
Accessing the value of an EmptyIterator
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
MyArrayIterator::rewind
0=>1
MyAppendIterator::valid
1=>2
MyAppendIterator::valid
-===DONE===
var_dump($it->valid());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
1=>2
int(1)
int(3)
Cannot seek to 3 which is behind offset 1 plus count 2
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
==SECOND==
int(1)
[0]=>
int(231)
}
-===DONE===
var_dump($it->current() == "a");
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
RecursiveArrayIteratorIterator::rewind() - BEGIN
MyRecursiveArrayIterator::rewind()
bool(true)
RecursiveArrayIteratorIterator::current()
bool(true)
-===DONE===
}
?>
-===DONE===
--EXPECT--
===1===
int(1)
===X===
Exception: Unsetting flag CALL_TO_STRING is not possible
Exception: Unsetting flag TOSTRING_USE_INNER is not possible
-===DONE===
}
?>
-===DONE===
--EXPECT--
int(0)
string(5) "Hello"
int(1)
string(5) "World"
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
NumericArrayIterator::__construct
NumericArrayIterator::rewind
int(56)
NumericArrayIterator::next
NumericArrayIterator::valid
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===
int(0)
int(0)
int(2)
int(3)
-===DONE===
MyArrayIterator::test('iterator_count', array(3 => 6));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===iterator_to_array===
State 0: __construct()
State 3: valid()
State 6: next()
int(2)
-===DONE===
MyArrayIterator::test('iterator_count', array(3 => 6));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===iterator_to_array===
State 7: __destruct()
===iterator_count===
State 7: __destruct()
int(2)
-===DONE===
MyArrayIterator::test('iterator_count', array(3 => 6));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===iterator_to_array===
State 0: __construct()
State 6: next()
State 7: __destruct()
int(2)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Error AppendIterator::append() expects parameter 1 to be Iterator, array given in %s on line %d
object(ArrayIterator)#%d (1) {
int(2)
int(2)
int(33)
-===DONE===
var_dump($it->getChildren());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
NULL
NULL
-===DONE===
$it->test($checks);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Exception: MyCachingIterator does not use a full cache (see CachingIterator::__construct)
Exception: MyCachingIterator does not use a full cache (see CachingIterator::__construct)
Notice: Undefined index: 3 in %siterator_044.php on line %d
NULL
-===DONE===
$it->show();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Exception: MyCachingIterator does not use a full cache (see CachingIterator::__construct)
Exception: MyCachingIterator does not use a full cache (see CachingIterator::__construct)
[3]=>
string(6) "FooBar"
}
-===DONE===
$it->show();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
MyCachingIterator::fill()
MyCachingIterator::show()
string(1) "0"
string(3) "foo"
string(3) "bar"
-===DONE===
$it->show();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
===0===
MyRecursiveArrayIterator::hasChildren()
MyRecursiveArrayIterator::hasChildren()
int(4)
int(4)
-===DONE===
$it->show();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(0)
string(3) "Bar"
int(2)
string(6) "FooBar"
-===DONE===
var_dump($ar->getArrayCopy());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
object(ArrayIterator)#%d (1) {
["storage":"ArrayIterator":private]=>
[""]=>
NULL
}
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(1)
array(3) {
%s(2) ",,"
}
}
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
string(3) "1,2"
array(3) {
int(6)
}
}
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
bool(true)
bool(true)
%s(2) ",,"
}
}
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
bool(true)
bool(true)
%s(2) ",,"
}
}
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(1)
array(2) {
%s(2) ",,"
}
}
-===DONE===
var_dump($ar);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
string(3) "1,2"
array(2) {
int(6)
}
}
-===DONE===
unset($obj);
?>
-===DONE===
--EXPECT--
Test::foo()
TestIteratorIterator::__destruct()
Test::foo()
-===DONE===
$sub->notify();
?>
-===DONE===
--EXPECT--
$sub->SubjectImpl::attach($ob1);
$sub->SubjectImpl::attach($ob1);
$sub->SubjectImpl::attach($ob3);
$sub->SubjectImpl::notify();
$ob3->ObserverImpl::update($sub);
-===DONE===
$sub->notify();
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
bool(false)
$sub->SubjectImpl::attach($ob1);
$ob3->ObserverImpl::update($sub);
MyObjectStorage::next()
MyObjectStorage::valid(0)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(4)
int(1)
string(1) "2"
string(3) "foo"
bool(true)
-===DONE===
var_dump($storage2);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(2)
int(1)
}
}
}
-===DONE===
var_dump($storage2);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(2)
object(TestClass)#%d (4) {
}
}
}
-===DONE===
var_dump(unserialize(serialize($storage)));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
int(2)
int(1)
}
}
}
-===DONE===
$a[$b] = 3;
var_dump($a == $b);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
bool(true)
bool(false)
bool(true)
bool(false)
-===DONE===
$a->removeAll($b);
var_dump($a->count());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(3)
int(2)
int(1)
-===DONE===
}
echo "\n";
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Count storage A: 2 x x
Count storage B: 2 x x
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Can't extract from an empty heap
2=>b
2=>2
1=>1
0=>0
-===DONE===
echo "Exception: ".$e->getMessage()."\n";
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
inserted 1
Exception: foo
Recovering..
int(1)
int(2)
-===DONE===
$h->next();
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
count($h) = 4
$h->count() = 4
2=>4
1=>1
0=>0
-===DONE===
var_dump($pq);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
object(SplPriorityQueue)#1 (3) {
["flags":"SplPriorityQueue":private]=>
}
}
}
-===DONE===
var_dump($h->compare(5, 5) == 0);
var_dump($h->compare(5, 4) > 0);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
bool(true)
bool(true)
bool(true)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
-- flags = BYPASS_KEY --
[0] => |-Array
[ \-3] => \-Array
[ |-0] => |-4
[ \-1] => \-c
-===DONE===
echo "InvalidArgumentException thrown\n";
}
?>
-===DONE===
--EXPECT--
InvalidArgumentException thrown
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECT--
RecursiveCachingIterator::__construct() expects parameter 1 to be RecursiveIterator, object given
-===DONE===
echo '[' . $it->key() . '] => ' . $it->getPrefix() . $it->getEntry() . $it->getPostfix() . "\n";
}
?>
-===DONE===
--EXPECT--
[0] => |-Array
[0] => | |-a
[3] => \-Array
[0] => |-4
[1] => \-c
-===DONE===
var_dump($it->key(), $it->getEntry(), $it->current());
}
?>
-===DONE===
--EXPECT--
string(7) "|-Array"
string(10) "| |-binary"
string(7) " \-1"
string(1) "c"
string(7) " \-c"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
-- flags = BYPASS_KEY --
[0] => |-Array
[ \-3] => \-Array
[ |-0] => |-4
[ \-1] => \-c
-===DONE===
}
?>
-===DONE===
--EXPECT--
Object of class stdClass could not be converted to string
-===DONE===
echo "OutOfRangeException thrown\n";
}
?>
-===DONE===
--EXPECT--
[a] => 035Array
[0] => 0145b
[0] => 0245d
OutOfRangeException thrown
OutOfRangeException thrown
-===DONE===
?>
-===DONE===
--EXPECT--
----
[3] => \-Array
[0] => |-4
[1] => \-c
-===DONE===
}
?>
-===DONE===
--EXPECT--
int(4)
Array
int(5)
int(3)
int(4)
-===DONE===
var_dump(count($a));
?>
-===DONE===
--EXPECT--
int(4)
-===DONE===
);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
Warning: class_parents(): Class foo does not exist in %sspl_003.php on line %d
string(3) "foo"
}
bool(false)
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
int(0)
int(1)
iterator_apply() expects parameter 3 to be array, int given
iterator_apply() expects parameter 2 to be a valid callback, function 'non_existing_function' not found or invalid function name
iterator_apply() expects at most 3 parameters, 4 given
-===DONE===
var_dump(iterator_to_array($it, true));
?>
-===DONE===
--EXPECT--
array(2) {
[0]=>
[1]=>
int(3)
}
-===DONE===
iterator_apply($it, array(new Foo, "foobar"));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Called foobar.
Called foobar.
Called foobar.
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
===EMPTY===
string(9) ".inc,.php"
bool(true)
===NOFUNCTION===
Exception: Function 'unavailable_autoload_function' not found (function 'unavailable_autoload_function' not found or invalid function name)
-===DONE===
var_dump(spl_autoload_functions());
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
bool(false)
array(1) {
string(12) "spl_autoload"
}
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
TestFunc1(TestClass)
TestFunc2(TestClass)
Exception: Class TestClass missing
-===DONE===
var_dump(class_exists("TestClass", true));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(1) {
[0]=>
}
MyAutoLoader::autoLoad(TestClass)
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
Exception: Passed array specifies a non static method but no object (non-static method MyAutoLoader::autoLoad() cannot be called statically)
MyAutoLoader::autoLoad(TestClass)
MyAutoLoader::autoThrow(TestClass)
Exception: Unavailable
-===DONE===
var_dump(class_exists("TestClass", true));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
array(1) {
[0]=>
}
MyAutoLoader::autoLoad(TestClass)
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
string(22) "MyAutoLoader::notExist"
Function 'MyAutoLoader::notExist' not found (class 'MyAutoLoader' does not have a method 'notExist')
string(8) "dynaLoad"
}
ok
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
====0====
string(10) "MyAutoLoad"
MyAutoLoader::dynaLoad(NoExistingTestClass)
Exception: Bla
int(0)
-===DONE===
$obj = new testclass;
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
%stestclass.inc
%stestclass.class.inc
bool(true)
-===DONE===
new C;
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
B -> C
A -> C
C -> C
-===DONE===
var_dump(class_exists("C", true));
?>
===DONE===
-<?php exit(0); ?>
--EXPECT--
var:2
bool(false)
var_dump(spl_autoload_functions());
?>
-===DONE===
--EXPECTF--
array(3) {
[0]=>
string(2) "d2"
}
}
-===DONE===
$y = new TestY;
?>
-===DONE===
--EXPECT--
closure called with class TestX
Autoloader('d1') called with TestX
WorkingAutoloader() called with TestX
WorkingAutoloader() called with TestY
-===DONE===
spl_autoload_register($c2);
$c = new foo;
?>
-===DONE===
--EXPECT--
a called
a2 called
b called
foo
-===DONE===
?>
-===DONE===
--EXPECT--
Flags must contain only one of CALL_TOSTRING, TOSTRING_USE_KEY, TOSTRING_USE_CURRENT, TOSTRING_USE_INNER
-===DONE===
echo $i->count()."\n";
}
?>
-===DONE===
--EXPECT--
1
2
3
4
5
-===DONE===
}
?>
-===DONE===
--EXPECT--
Exception raised
-===DONE===
}
?>
-===DONE===
--EXPECT--
Exception raised
-===DONE===
?>
-===DONE===
--EXPECT--
array(3) {
[0]=>
int(7)
invalid argument exception
NULL
-===DONE===
}
?>
-===DONE===
--EXPECT--
IteratorIterator::__construct() expects at most 2 parameters, 3 given
-===DONE===
?>
-===DONE===
--EXPECT--
Parameter offset must be >= 0
Parameter count must either be -1 or a value greater than or equal 0
-===DONE===
var_dump($exp === $out);
}
?>
-===DONE===
--EXPECTF--
object(SplDoublyLinkedList)#%d (2) {
["flags":"SplDoublyLinkedList":private]=>
}
}
bool(true)
-===DONE===
// Access the sqlite3_stmt object via the php_sqlite3_stmt container
$stmt->reset();
?>
-==DONE==
--EXPECTF--
Warning: SQLite3Stmt::reset(): The SQLite3 object has not been correctly initialised in %s
-==DONE==
echo gettype($row[0]), PHP_EOL;
}
?>
-===DONE===
--EXPECT--
integer
integer
-===DONE===
$stmt->execute();
var_dump($db->querySingle("SELECT bar FROM foo LIMIT 1"));
?>
-===DONE===
--EXPECT--
float(17)
-===DONE===
var_dump($r->fetchArray(SQLITE3_ASSOC));
?>
-==DONE==
--EXPECT--
array(3) {
["a"]=>
["c"]=>
float(3.15)
}
-==DONE==
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECTF--
*** Testing array_diff_key() : error conditions ***
-- Testing array_diff_key() function with no arguments --
At least 2 parameters are required, 0 given
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
--resource--
Expected parameter 1 to be an array, resource given
Expected parameter 1 to be an array, resource given
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
--resource--
Expected parameter 2 to be an array, resource given
Expected parameter 2 to be an array, resource given
-===DONE===
var_dump( array_diff_key($value, $input_array) );
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
[18]=>
string(4) "0x12"
}
-===DONE===
var_dump( array_diff_key($input_array, $float_indx_array) );
var_dump( array_diff_key($float_indx_array, $input_array) );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
}
array(0) {
}
-===DONE===
var_dump( array_diff_key($input_array, $boolean_indx_array) );
var_dump( array_diff_key($boolean_indx_array, $input_array) );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
}
array(0) {
}
-===DONE===
var_dump( array_diff_key($value, $input_array) );
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
}
array(0) {
}
-===DONE===
var_dump( array_diff_key($array1, $array2) );
var_dump( array_diff_key($array2, $array1) );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_key() : usage variation ***
string(3) "two"
}
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : error conditions ***
-- Testing array_diff_uassoc() function with less than expected no. of arguments --
At least 3 parameters are required, 2 given
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
--resource--
Expected parameter 1 to be an array, resource given
-===DONE===
var_dump( array_diff_uassoc($float_indx_array, $input_array, "strcasecmp") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
[-10]=>
string(5) "-10.5"
}
-===DONE===
var_dump( array_diff_uassoc($boolean_indx_array, $input_array, "strcasecmp") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
[0]=>
string(5) "boolF"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
}
array(0) {
}
-===DONE===
var_dump( array_diff_uassoc($array2, $array1, "strcasecmp") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
}
array(0) {
}
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
--resource--
Expected parameter 2 to be an array, resource given
-===DONE===
var_dump( array_diff_uassoc($arr_float, $arr_default_int, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
}
array(0) {
}
-===DONE===
var_dump( array_diff_uassoc($arr_string_float, $arr_float, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
["1.00"]=>
string(4) "2.00"
}
-===DONE===
var_dump( array_diff_uassoc($arr_string_float, $arr_string_int, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
["1.00"]=>
string(4) "2.00"
}
-===DONE===
var_dump( array_diff_uassoc($arr_string_float, $arr_default_int, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
["1.00"]=>
string(4) "2.00"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_uassoc() : usage variation ***
[-7]=>
int(-7)
}
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
--resource--
Expected parameter 1 to be an array, resource given
Expected parameter 1 to be an array, resource given
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
array_diff_ukey() expects parameter 3 to be a valid callback, function 'unknown_function' not found or invalid function name
array_diff_ukey() expects parameter 3 to be a valid callback, function 'unknown_function' not found or invalid function name
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
--resource--
Expected parameter 2 to be an array, resource given
Expected parameter 2 to be an array, resource given
-===DONE===
var_dump( array_diff_ukey($array1, $array2, 'strcasecmp') );
var_dump( array_diff_ukey($array2, $array1, 'strcasecmp') );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
string(3) "two"
}
}
-===DONE===
var_dump( array_diff_ukey($input_array, $value, 'key_compare_func') );
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
[10]=>
string(3) "0xA"
}
-===DONE===
var_dump( array_diff_ukey($input_array, $float_indx_array, 'key_compare_func') );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
[20]=>
string(2) "20"
}
-===DONE===
var_dump( array_diff_ukey($input_array, $boolean_indx_array, 'key_compare_func') );
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
["false"]=>
int(0)
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
[10]=>
string(2) "10"
}
-===DONE===
}
}
}
-echo '== Done ==';
?>
-===============Done====================
--EXPECT--
===========================
start: 0 num: 0 value: 1
[3]=>
string(1) "f"
}
-== Done =================Done====================
var_dump(array_filter(array()));
-echo '== DONE ==';
?>
--EXPECTF--
Odd :
}
array(0) {
}
-== DONE ==
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : error conditions ***
-- Testing array_intersect_key() function with no arguments --
At least 2 parameters are required, 0 given
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
--resource var--
Expected parameter 1 to be an array, resource given
Expected parameter 1 to be an array, resource given
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
--resource var--
Expected parameter 2 to be an array, resource given
Expected parameter 2 to be an array, resource given
-===DONE===
var_dump( array_intersect_key($value,$input_array ) );
}
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
[-7]=>
string(4) "-0x7"
}
-===DONE===
var_dump( array_intersect_key($input_array, $float_indx_array) );
var_dump( array_intersect_key($float_indx_array,$input_array ) );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
[-10]=>
string(5) "-10.5"
}
-===DONE===
var_dump( array_intersect_key($input_array, $boolean_indx_array) );
var_dump( array_intersect_key($boolean_indx_array,$input_array ) );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
[0]=>
string(5) "boolF"
}
-===DONE===
var_dump( array_intersect_key($value,$input_array ) );
}
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
[""]=>
string(5) "unset"
}
-===DONE===
var_dump( array_intersect_key($array1, $array2) );
var_dump( array_intersect_key($array2,$array1 ) );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_key() : usage variation ***
array(2) {
int(8)
}
}
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
--resource--
Expected parameter 1 to be an array, resource given
Expected parameter 1 to be an array, resource given
-===DONE===
$obj = new MyClass();
var_dump( array_intersect_uassoc($array1, $array2, array($obj,'class_compare_func')) );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
["a"]=>
string(5) "green"
}
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
--resource--
Expected parameter 2 to be an array, resource given
Expected parameter 2 to be an array, resource given
-===DONE===
echo "\n-- Result of integers and strings containing floating points intersection --\n";
var_dump( array_intersect_uassoc($arr_default_int, $arr_string_float, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
-- Result of integers and strings containing floating points intersection --
array(0) {
}
-===DONE===
echo "\n-- Result of floating points and strings containing floating point intersection --\n";
var_dump( array_intersect_uassoc($arr_float, $arr_string_float, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
-- Result of floating points and strings containing floating point intersection --
array(0) {
}
-===DONE===
echo "\n-- Result of strings containing integers and strings containing floating points intersection --\n";
var_dump( array_intersect_uassoc($arr1_string_int, $arr2_string_float, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
-- Result of strings containing integers and strings containing floating points intersection --
array(0) {
}
-===DONE===
echo "\n-- Testing array_intersect_uassoc() function when \$array2 is referencd to \$array1 --\n";
var_dump( array_intersect_uassoc($array1, $array2, "strcasecmp") );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_uassoc() : usage variation ***
[1]=>
string(1) "a"
}
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
--resource var--
Expected parameter 1 to be an array, resource given
Expected parameter 1 to be an array, resource given
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
--resource var--
Expected parameter 2 to be an array, resource given
Expected parameter 2 to be an array, resource given
-===DONE===
echo "\n-- Result of integers and strings containing floating points intersection --\n";
var_dump( array_intersect_ukey($arr_default_int, $arr_string_float, "key_compare_func") );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
[1]=>
int(2)
}
-===DONE===
echo "\n-- Result of floating points and strings containing floating point intersection --\n";
var_dump( array_intersect_ukey($arr_float, $arr_string_float, 'key_compare_func') );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
[1]=>
float(2)
}
-===DONE===
echo "\n-- Result of strings containing integers and strings containing floating points intersection --\n";
var_dump( array_intersect_ukey($arr1_string_int, $arr2_string_float, 'key_compare_func') );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
[1]=>
string(1) "2"
}
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing array_intersect_ukey() : usage variation ***
array_intersect_ukey() expects parameter 3 to be a valid callback, function 'unknown_function' not found or invalid function name
array_intersect_ukey() expects parameter 3 to be a valid callback, function 'unknown_function' not found or invalid function name
-===DONE===
$obj = new MyClass();
var_dump( array_intersect_ukey($array1, $array2, array($obj,'class_compare_func')) );
?>
-===DONE===
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
["green"]=>
int(3)
}
-===DONE===
test(array('InterClass', 'square'), array(1, 2));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
*** Testing array_map() : object functionality ***
-- simple class with public variable and method --
[1]=>
int(4)
}
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : basic functionality ***
["row1"]=>
int(2)
}
-===DONE===
var_dump($ar1, $ar2);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : basic functionality - renumbering of numeric keys ***
[2]=>
int(2)
}
-===DONE===
var_dump($a, $b);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : case-sensitive
array(7) {
[6]=>
string(3) "3 e"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : error conditions ***
-- Testing array_multisort() function with repeated flags --
Argument #3 is expected to be an array or sorting flag that has not already been specified
-===DONE===
var_dump($a, $b);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : case-insensitive
array(7) {
[6]=>
string(3) "3 e"
}
-===DONE===
var_dump($a, $b);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : natural sorting
array(5) {
[4]=>
string(4) "20 c"
}
-===DONE===
var_dump($a, $b);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : natural sorting case-sensitive
array(7) {
[6]=>
string(4) "20 c"
}
-===DONE===
var_dump($a, $b);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : natural sorting case-insensitive
array(7) {
[6]=>
string(4) "20 c"
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : usage variation ***
--unset var--
Argument #1 is expected to be an array or a sort flag
-===DONE===
var_dump(array_multisort(array(1,3,2,4)));
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : Testing with anonymous arguments ***
bool(true)
-===DONE===
var_dump(array_multisort(array()));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
*** Testing array_multisort() : Testing with empty array ***
bool(true)
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : usage variation ***
--unset var--
Argument #2 is expected to be an array or a sort flag
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : usage variation ***
--unset var--
Argument #3 is expected to be an array or a sort flag
-===DONE===
var_dump($arr3);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : Testing with multiple array arguments ***
bool(true)
[3]=>
int(9)
}
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : Testing all array sort specifiers ***
array(3) {
[2]=>
int(2)
}
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : Testing all array sort specifiers ***
array(3) {
[2]=>
string(2) "aa"
}
-===DONE===
var_dump($inputs);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : usage variation - test sort order of all types***
bool(true)
object(classWithoutToString)#2 (0) {
}
}
-===DONE===
var_dump($inputs);
?>
-===DONE===
--EXPECT--
*** Testing array_multisort() : usage variation - test sort order of all types***
bool(true)
["string DQ"]=>
string(6) "string"
}
-===DONE===
var_dump($inputs);
?>
-===DONE===
--EXPECTF--
*** Testing array_multisort() : usage variation - test sort order of all types***
object(classWithoutToString)#2 (0) {
}
}
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECTF--
*** Testing array_product() : variation - using non numeric values ***
boolean (true)
array
int(1)
-===DONE===
echo "\n-- Testing array_product() function with a keyed array array --\n";
var_dump( array_product(array("bob" => 2, "janet" => 5)) );
?>
-===DONE===
--EXPECT--
*** Testing array_product() : variations ***
-- Testing array_product() function with a keyed array array --
int(10)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_product() : variations - negative numbers***
-- Testing array_product() function with negative floats --
float(-9.9999999E+15)
-===DONE===
var_dump( array_product($array) );
?>
-===DONE===
--EXPECT--
*** Testing array_product() : variations ***
-- Testing array_product() function with a very large array --
float(INF)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing array_reduce() : variation ***
--- Testing with a callback with too many parameters ---
Exception: Too few arguments to function threeArgs(), 2 passed and exactly 3 expected
-===DONE===
var_dump(array_reduce($array, array(new A(), "adder2")));
?>
-===DONE===
--EXPECT--
*** Testing array_reduce() : variation - object callbacks ***
--- Instance method callback ---
int(1)
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_assoc() : variation - testing with multiple array arguments ***
array(2) {
["0.5"]=>
int(5)
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_assoc() : usage variation ***
--unset var--
Expected parameter 1 to be an array, null given
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_assoc() : usage variation ***
--unset var--
Expected parameter 2 to be an array, null given
-===DONE===
var_dump(array_udiff_assoc($arr1, $arr2, 'too_few_parameters'));
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_assoc() : usage variation - differing comparison functions***
[0]=>
int(1)
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_uassoc() : usage variation ***
--unset var--
Expected parameter 1 to be an array, null given
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_uassoc() : usage variation ***
--unset var--
Expected parameter 2 to be an array, null given
-===DONE===
var_dump(array_udiff_uassoc($arr1, $arr2, 'too_few_parameters', 'too_few_parameters'));
?>
-===DONE===
--EXPECT--
*** Testing array_udiff_uassoc() : usage variation - differing comparison functions***
[0]=>
int(1)
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_udiff() : usage variation ***
--unset var--
Expected parameter 1 to be an array, null given
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_udiff() : usage variation ***
--unset var--
Expected parameter 2 to be an array, null given
-===DONE===
var_dump(array_udiff($arr1, $arr2, 'too_few_parameters'));
?>
-===DONE===
--EXPECT--
*** Testing array_udiff() : usage variation ***
-- comparison function taking too few parameters --
array(0) {
}
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_assoc() : basic functionality - testing with multiple array arguments ***
array(2) {
[3]=>
string(5) "three"
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_assoc() : usage variation ***
--unset var--
Expected parameter 1 to be an array, null given
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_assoc() : usage variation ***
--unset var--
Expected parameter 2 to be an array, null given
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_assoc() : usage variation - differing comparison functions***
array(0) {
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_uassoc() : usage variation ***
--unset var--
Expected parameter 1 to be an array, null given
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_uassoc() : usage variation ***
--unset var--
Expected parameter 2 to be an array, null given
-===DONE===
var_dump(array_uintersect_uassoc($arr1, $arr2, 'too_few_parameters', 'too_few_parameters'));
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect_uassoc() : usage variation - incorrect callbacks ***
-- comparison function taking too few parameters --
array(0) {
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect() : usage variation ***
--unset var--
Expected parameter 1 to be an array, null given
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect() : usage variation ***
--unset var--
Expected parameter 2 to be an array, null given
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing array_uintersect() : usage variation - differing comparison functions***
array(0) {
}
-===DONE===
var_dump($v);
}
-echo "==Done==\n";
?>
--EXPECT--
==Mixed==
==Negative==
int(-2)
string(1) "a"
-==Done==
echo "Caught: " . $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
Caught: Error
-===DONE===
f();
?>
-==Done==
--EXPECTF--
*** Testing compact() : usage variations - variables outside of current scope ***
["c"]=>
string(3) "f.c"
}
-==Done==
next($array);
var_dump(current($array));
?>
-===DONE===
--EXPECT--
*** Testing current() : basic functionality ***
string(4) "zero"
string(3) "one"
int(3)
bool(false)
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECTF--
*** Testing current() : usage variations ***
-- Iteration 11 : resource data --
resource(%d) of type (stream)
-===DONE===
echo "\$array2: ";
var_dump(current($array2));
?>
-===DONE===
--EXPECT--
*** Testing current() : usage variations ***
-- Position after calling next() --
$array1: string(3) "one"
$array2: string(3) "one"
-===DONE===
// see if internal pointer is in the same position from when accessing this inner array
var_dump(current($multi_array[3][3][3][1]));
?>
-===DONE===
--EXPECT--
*** Testing current() : usage variations ***
Current Position: string(3) "two"
string(3) "two"
int(1)
-===DONE===
current_variation5($a);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
*** Testing current() : usage variations ***
string(5) "maybe"
string(5) "maybe"
string(2) "no"
-===DONE===
$array[2] = 'foo';
var_dump(end($array));
?>
-===DONE===
--EXPECT--
*** Testing end() : basic functionality ***
-- Add a new element to array --
string(3) "foo"
-===DONE===
echo "\n-- Pass a sub-array as \$array_arg --\n";
var_dump(end($array_arg[0]));
?>
-===DONE===
--EXPECT--
*** Testing end() : usage variations ***
-- Pass a sub-array as $array_arg --
int(7)
-===DONE===
echo "\$array2: ";
var_dump(current($array2));
?>
-===DONE===
--EXPECT--
*** Testing end() : usage variations ***
-- Position after calling end() --
$array1: string(3) "two"
$array2: string(3) "two"
-===DONE===
next($array);
var_dump(key($array));
?>
-===DONE===
--EXPECT--
*** Testing key() : basic functionality ***
-- Past end of the array --
NULL
-===DONE===
$iterator++;
};
?>
-===DONE===
--EXPECT--
*** Testing key() : usage variations ***
-- Iteration 12 : unset data --
string(0) ""
-===DONE===
echo "\$array2: ";
var_dump(key($array2));
?>
-===DONE===
--EXPECT--
*** Testing key() : usage variations ***
-- Position after calling next() --
$array1: int(1)
$array2: int(1)
-===DONE===
// see if internal pointer is in the same position from when accessing this inner array
var_dump(key($multi_array[3][3][3][1]));
?>
-===DONE===
--EXPECT--
*** Testing key() : usage variations ***
Current Position: int(2)
int(2)
int(0)
-===DONE===
var_dump(max($longVals));
?>
-===DONE===
--EXPECT--
int(9223372036854775807)
int(9223372036854775807)
-===DONE===
var_dump(min($longVals));
?>
-===DONE===
--EXPECT--
int(-9223372036854775808)
int(-9223372036854775808)
-===DONE===
echo key($array) . " => " . current($array) . "\n";
var_dump(next($array));
?>
-===DONE===
--EXPECT--
*** Testing next() : basic functionality ***
0 => zero
string(3) "two"
2 => two
bool(false)
-===DONE===
echo "\n-- Pass a sub-array as \$array_arg --\n";
var_dump(next($array_arg[0]));
?>
-===DONE===
--EXPECT--
*** Testing next() : usage variations ***
-- Pass a sub-array as $array_arg --
int(8)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing prev() : basic functionality ***
2 => two
string(4) "help"
string(3) "one"
bool(false)
-===DONE===
echo "\n-- Pass a sub-array as \$array_arg --\n";
var_dump(prev($array_arg[0]));
?>
-===DONE===
--EXPECT--
*** Testing prev() : usage variations ***
-- Pass a sub-array as $array_arg --
int(8)
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
Invalid range supplied: start=0 end=inf
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECT--
Invalid range supplied: start=inf end=inf
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
The supplied range exceeds the maximum array size: start=0 end=%d
-===DONE===
echo $e->getMessage() . "\n";
}
?>
-===DONE===
--EXPECTF--
The supplied range exceeds the maximum array size: start=-%d end=0
-===DONE===
echo "\n-- Call to reset() --\n";
var_dump(reset($array));
?>
-===DONE===
--EXPECT--
*** Testing reset() : basic functionality ***
-- Call to reset() --
string(4) "zero"
-===DONE===
unset($array[0]);
var_dump(reset($array));
?>
-===DONE===
--EXPECT--
*** Testing reset() : usage variations ***
-- Unset First element in array and check reset() --
string(1) "b"
-===DONE===
echo "\$array2: ";
var_dump(current($array2));
?>
-===DONE===
--EXPECT--
*** Testing reset() : usage variations ***
string(4) "zero"
$array1: string(4) "zero"
$array2: string(4) "zero"
-===DONE===
var_dump( usort($string_key_arg, 'cmp') );
var_dump($string_key_arg);
?>
-===DONE===
--EXPECT--
*** Testing usort() : basic functionality ***
[3]=>
int(10)
}
-===DONE===
var_dump( usort($array_arg, 'multiple_cmp') );
var_dump($array_arg);
?>
-===DONE===
--EXPECTF--
*** Testing usort() : object functionality ***
bool(true)
string(5) "apple"
}
}
-===DONE===
var_dump( usort($array_arg, 'cmp_function') );
var_dump($array_arg);
?>
-===DONE===
--EXPECTF--
*** Testing usort() : object functionality ***
-- Testing usort() with StaticClass objects --
NULL
}
}
-===DONE===
var_dump( usort($array_arg, 'cmp') );
var_dump($array_arg);
?>
-===DONE===
--EXPECT--
*** Testing usort() : usage variation ***
[3]=>
string(9) "Pineapple"
}
-===DONE===
echo "\n-- Sorted array after usort() function call --\n";
var_dump($array_arg);
?>
-===DONE===
--EXPECT--
*** Testing usort() : usage variation ***
bool(true)
[14]=>
int(0)
}
-===DONE===
var_dump( usort($empty_array, 'cmp_function') );
var_dump($empty_array);
?>
-===DONE===
--EXPECT--
*** Testing usort() : usage variation ***
bool(true)
array(0) {
}
-===DONE===
var_dump( usort($heredoc_values, 'cmp_function') );
var_dump($heredoc_values);
?>
-===DONE===
--EXPECTF--
*** Testing usort() : usage variation ***
string(%d) "heredoc string with!@# and 123
Test this!!!"
}
-===DONE===
echo "-- Array after call to usort() --\n";
var_dump($array_args[5]);
?>
-===DONE===
--EXPECT--
*** Testing usort() : usage variation ***
[4]=>
int(54)
}
-===DONE===
var_dump( usort($array_arg, $cmp_function) );
var_dump($array_arg);
?>
-===DONE===
--EXPECT--
*** Testing usort() : usage variation ***
[3]=>
string(9) "Pineapple"
}
-===DONE===
var_dump($temp_array2);
?>
-===DONE===
--EXPECTF--
*** Testing usort() : usage variation ***
[4]=>
string(6) "orange"
}
-===DONE===
var_dump( usort($array_arg, 'cmp_function') );
var_dump($array_arg);
?>
-===DONE===
--EXPECT--
*** Testing usort() : usage variation ***
[4]=>
int(200)
}
-===DONE===
assert($a != 0);
?>
-==DONE==
--EXPECT--
assertion failed - a - 18,"assert($a != 0)"
assertion failed - b - 22,"assert($a != 0)"
-==DONE==
echo "created in $d ms\n";
echo ((bool)($d >= 0)) . "\n";
?>
-===DONE===
--EXPECTF--
$_SERVER['REQUEST_TIME']: %d
$_SERVER['REQUEST_TIME_FLOAT']: %f
microtime(true): %f
created in %f ms
1
-===DONE===
}
echo "ok\n";
?>
-===DONE===
--EXPECT--
ok
-===DONE===
C::test3();
?>
-===DONE===
--EXPECT--
A
-
-
B
C
-===DONE===
C::test();
?>
-===DONE===
--EXPECT--
A
-
C
B
B
-===DONE===
echo "\n-- From a child's static context --\n";
Child::testStatic();
?>
-===DONE===
--EXPECT--
*** Testing get_class_vars() : testing visibility
["prots"]=>
string(20) "protected static var"
}
-===DONE===
var_dump( property_exists(10, $property_name) );
?>
-===DONE===
--EXPECTF--
*** Testing property_exists() : error conditions ***
Warning: First parameter must either be an object or the name of an existing class in %sproperty_exists_error.php on line %d
NULL
-===DONE===
var_dump(property_exists("AutoTest", "foo"));
?>
-===DONE===
--EXPECT--
*** Testing property_exists() : class auto loading ***
testing __get magic method
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
string(%d) "%s/_test/documents/projects/myproject/vendor/name/library/classpath"
bool(true)
bool(true)
string(%d) "%s\_test\documents\projects\myproject\vendor\name\library\classpath"
string(%d) "%s/_test/documents/projects/myproject/vendor/name/library"
-===DONE===
var_dump(chdir($level_two_dir_name));
var_dump(getcwd());
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/chdir_basic-win32-mb';
-- Testing chdir() with relative paths: --
bool(true)
string(%d) "%s私はガラスを食べられますlevel_one%e私はガラスを食べられますlevel_two"
-===DONE===
var_dump(chdir($level1_two_dir_name));
var_dump(getcwd());
?>
-===DONE===
--CLEAN--
<?php
$file_path = __DIR__;
-- Testing chdir() with relative paths: --
bool(true)
string(%d) "%slevel1_one%elevel1_two"
-===DONE===
var_dump(chdir($directory));
?>
-===DONE===
--EXPECTF--
*** Testing chdir() : error conditions ***
Warning: chdir(): %s (errno %d) in %s on line %d
bool(false)
-===DONE===
var_dump(chdir($directory));
?>
-===DONE===
--EXPECTF--
*** Testing chdir() : error conditions ***
Warning: chdir(): %s (errno %d) in %s on line %d
bool(false)
-===DONE===
var_dump(chdir("../../$level_one_dir_name"));
var_dump(getcwd());
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/chdir_variation2-win32-mb';
bool(true)
bool(true)
string(%d) "%s私はガラスを食べられますlevel_one"
-===DONE===
var_dump(getcwd());
?>
-===DONE===
--CLEAN--
<?php
$file_path = __DIR__;
bool(true)
bool(true)
string(%d) "%slevel2_one"
-===DONE===
echo "-- Check Directory Handle: --\n";
var_dump($dh2);
?>
-===DONE===
--CLEAN--
<?php
$base_dir = __DIR__;
NULL
-- Check Directory Handle: --
resource(%d) of type (Unknown)
-===DONE===
echo "-- Check Directory Handle: --\n";
var_dump($dh2);
?>
-===DONE===
--CLEAN--
<?php
$base_dir = __DIR__;
NULL
-- Check Directory Handle: --
resource(%d) of type (Unknown)
-===DONE===
echo "Directory Handle: ";
var_dump($dh);
?>
-===DONE===
--CLEAN--
<?php
$directory = __DIR__ . "/私はガラスを食べられますclosedir_variation2";
-- Close directory handle second time: --
closedir(): %s is not a valid Directory resource
Directory Handle: resource(%d) of type (Unknown)
-===DONE===
echo "Directory Handle: ";
var_dump($dh);
?>
-===DONE===
--CLEAN--
<?php
$directory = __DIR__ . "/closedir_variation2";
-- Close directory handle second time: --
closedir(): supplied resource is not a valid Directory resource
Directory Handle: resource(%d) of type (Unknown)
-===DONE===
fclose($fp);
}
?>
-===DONE===
--EXPECTF--
*** Testing closedir() : usage variations ***
-- Check file pointer: --
resource(%d) of type (stream)
-===DONE===
}
?>
-==DONE==
--CLEAN--
<?php
$base = __DIR__ . DIRECTORY_SEPARATOR . "bug73971";
string(1) "."
string(2) ".."
string(432) "テストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテストテスト"
-==DONE==
chdir($directory);
var_dump(getcwd());
?>
-===DONE===
--CLEAN--
<?php
$directory = __DIR__ . "/私はガラスを食べられますgetcwd_basic";
*** Testing getcwd() : basic functionality ***
string(%d) "%s"
string(%d) "%s%e私はガラスを食べられますgetcwd_basic"
-===DONE===
chdir($directory);
var_dump(getcwd());
?>
-===DONE===
--CLEAN--
<?php
$directory = __DIR__ . "/getcwd_basic";
*** Testing getcwd() : basic functionality ***
string(%d) "%s"
string(%d) "%s%egetcwd_basic"
-===DONE===
closedir($dh2);
var_dump($dh2);
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/opendir_basic-win32-mb';
-- Close directory handles: --
resource(%d) of type (Unknown)
resource(%d) of type (Unknown)
-===DONE===
closedir($dh2);
var_dump($dh2);
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/opendir_basic';
-- Close directory handles: --
resource(%d) of type (Unknown)
resource(%d) of type (Unknown)
-===DONE===
chdir(__DIR__);
var_dump(opendir('idonotexist'));
?>
-===DONE===
--EXPECTF--
*** Testing opendir() : error conditions ***
Warning: opendir(idonotexist): failed to open dir: %s in %s on line %d
bool(false)
-===DONE===
closedir($dh1);
closedir($dh2);
?>
-===DONE===
--CLEAN--
<?php
$path = __DIR__ . "/私はガラスを食べられますopendir_variation3";
resource(%d) of type (stream)
New resource created
-===DONE===
closedir($dh1);
closedir($dh2);
?>
-===DONE===
--CLEAN--
<?php
$path = __DIR__ . "/opendir_variation3";
resource(%d) of type (stream)
New resource created
-===DONE===
unset($dh);
}
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/opendir_variation4-win32-mb';
-- $path = '../../'私はガラスを食べられますlevel_one': --
bool(true)
resource(%d) of type (stream)
-===DONE===
unset($dh);
}
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/opendir_variation4';
-- $path = '../../'level_one': --
bool(true)
resource(%d) of type (stream)
-===DONE===
closedir($dir_handle2);
}
?>
-===DONE===
--CLEAN--
<?php
$parent_dir_path = __DIR__ . "/opendir_variation5";
Warning: opendir(%s/opendir_variation5/sub_dir/child_dir): failed to open dir: %s in %s on line %d
bool(false)
-===DONE===
var_dump( opendir($dir_path . "/sub?dir1") );
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/opendir_variation6";
Warning: opendir(%s/opendir_variation6/sub?dir1): failed to open dir: %s in %s on line %d
bool(false)
-===DONE===
var_dump( opendir($dir_path . "/sub?dir1") );
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/opendir_variation6";
Warning: opendir(%s/opendir_variation6/sub?dir1): failed to open dir: %s in %s on line %d
bool(false)
-===DONE===
$iterator++;
}
?>
-===DONE===
--CLEAN--
<?php
// deleting temporary directory
-- Iteration 10 --
bool(true)
resource(%d) of type (stream)
-===DONE===
delete_files($path, 3);
closedir($dh);
?>
-===DONE===
--CLEAN--
<?php
$path = __DIR__ . '/私はガラスを食べられますreaddir_basic';
string(9) "file1.tmp"
string(9) "file2.tmp"
string(9) "file3.tmp"
-===DONE===
delete_files($path, 3);
closedir($dh);
?>
-===DONE===
--CLEAN--
<?php
$path = __DIR__ . '/readdir_basic';
string(9) "file1.tmp"
string(9) "file2.tmp"
string(9) "file3.tmp"
-===DONE===
var_dump($entry);
}
?>
-===DONE===
--CLEAN--
<?php
$path = __DIR__ . '/私はガラスを食べられますreaddir_variation2';
-- Pass an empty directory to readdir() --
string(1) "."
string(2) ".."
-===DONE===
var_dump($entry);
}
?>
-===DONE===
--CLEAN--
<?php
$path = __DIR__ . '/readdir_variation2';
-- Pass an empty directory to readdir() --
string(1) "."
string(2) ".."
-===DONE===
closedir($dir_handle);
?>
-===DONE===
--CLEAN--
<?php
$path_top = __DIR__ . '/readdir_variation3-win32-mb';
[4]=>
string(46) "私はガラスを食べられますsub_folder"
}
-===DONE===
closedir($dir_handle);
?>
-===DONE===
--CLEAN--
<?php
$path_top = __DIR__ . '/readdir_variation3';
[4]=>
string(10) "sub_folder"
}
-===DONE===
closedir($dir_handle);
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/私はガラスを食べられますreaddir_variation4/";
[15]=>
string(51) "私はガラスを食べられますsingle_file.tmp"
}
-===DONE===
closedir($dir_handle);
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/readdir_variation4/";
[15]=>
string(15) "single_file.tmp"
}
-===DONE===
$iterator++;
}
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/readdir_variation5";
resource(%d) of type (stream)
-- Calling readdir() --
string(%d) "%s"
-===DONE===
closedir($dir_handle1);
closedir();
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/私はガラスを食べられますreaddir_variation6";
string(59) "私はガラスを食べられますreaddir_variation61.tmp"
string(59) "私はガラスを食べられますreaddir_variation62.tmp"
string(59) "私はガラスを食べられますreaddir_variation63.tmp"
-===DONE===
closedir($dir_handle1);
closedir();
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/readdir_variation6";
string(23) "readdir_variation61.tmp"
string(23) "readdir_variation62.tmp"
string(23) "readdir_variation63.tmp"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing readdir() : usage variations ***
resource(%d) of type (stream)
%d is not a valid Directory resource
-===DONE===
delete_files($dir_path1, 1, "私はガラスを食べられますfile");
delete_files($dir_path2, 1, "私はガラスを食べられますfile", 2);
?>
-===DONE===
--CLEAN--
<?php
$dir_path1 = __DIR__ . "/私はガラスを食べられますrewinddir_basic_dir1";
}
NULL
bool(true)
-===DONE===
delete_files($dir_path1, 1);
delete_files($dir_path2, 1, 'file', 2);
?>
-===DONE===
--CLEAN--
<?php
$dir_path1 = __DIR__ . "/rewinddir_basic_dir1";
}
NULL
bool(true)
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . '/私はガラスを食べられますrewinddir_variation2';
-- Call to rewinddir() --
rewinddir(): %s is not a valid Directory resource
-===DONE===
echo $e->getMessage(), "\n";
}
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . '/rewinddir_variation2';
-- Call to rewinddir() --
rewinddir(): supplied resource is not a valid Directory resource
-===DONE===
echo "rewinddir() does not work on file pointers\n";
}
?>
-===DONE===
--EXPECTF--
*** Testing rewinddir() : usage variations ***
-- Check if rewinddir() has repositioned the file pointer --
rewinddir() does not work on file pointers
-===DONE===
delete_files($directory, 3, "私はガラスを食べられますfile");
?>
-===DONE===
--CLEAN--
<?php
$directory = __DIR__ . '/私はガラスを食べられますscandir_basic';
[4]=>
string(1) "."
}
-===DONE===
delete_files($directory, 3);
?>
-===DONE===
--CLEAN--
<?php
$directory = __DIR__ . '/scandir_basic';
[4]=>
string(1) "."
}
-===DONE===
echo "\n-- Pass scandir() a relative path that does not exist --\n";
var_dump(scandir('/idonotexist'));
?>
-===DONE===
--EXPECTF--
*** Testing scandir() : error conditions ***
Warning: scandir(): (errno %d): %s in %s on line %d
bool(false)
-===DONE===
delete_files($dir, 2, "私はガラスを食べられますfile");
?>
-===DONE===
--CLEAN--
<?php
$dir = __DIR__ . '/私はガラスを食べられますscandir_variation10';
bool(true)
bool(true)
bool(true)
-===DONE===
delete_files($dir, 2);
?>
-===DONE===
--CLEAN--
<?php
$dir = __DIR__ . '/scandir_variation10';
bool(true)
bool(true)
bool(true)
-===DONE===
@delete_files($level_one_dir_path, 2, '私はガラスを食べられますlevel_one');
@delete_files($level_two_dir_path, 2, '私はガラスを食べられますlevel_two');
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/scandir_variation4-win32-mb';
[4]=>
string(45) "私はガラスを食べられますlevel_two"
}
-===DONE===
@delete_files($level_one_dir_path, 2, 'level_one');
@delete_files($level_two_dir_path, 2, 'level_two');
?>
-===DONE===
--CLEAN--
<?php
$base_dir_path = __DIR__ . '/scandir_variation4';
[4]=>
string(9) "level_two"
}
-===DONE===
echo "\n-- After restricting parent directory --\n";
var_dump(scandir($child_dir_path));
?>
-===DONE===
--CLEAN--
<?php
$parent_dir_path = __DIR__ . "/scandir_variation5";
Warning: scandir(): (errno %d): %s in %s on line %d
bool(false)
-===DONE===
var_dump( scandir($dir_path . "/sub?dir1") );
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/scandir_variation6";
Warning: scandir(): (errno %d): %s in %s on line %d
bool(false)
-===DONE===
$iterator++;
}
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/scandir_variation7";
[1]=>
string(2) ".."
}
-===DONE===
@unlink($dir_path . $file_name);
}
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/私はガラスを食べられますscandir_variation8";
[15]=>
string(51) "私はガラスを食べられますsingle_file.tmp"
}
-===DONE===
@unlink($dir_path . $file_name);
}
?>
-===DONE===
--CLEAN--
<?php
$dir_path = __DIR__ . "/scandir_variation8";
[15]=>
string(15) "single_file.tmp"
}
-===DONE===
delete_files($dir, 2, "私はガラスを食べられますfile");
?>
-===DONE===
--CLEAN--
<?php
$dir = __DIR__ . '/私はガラスを食べられますscandir_variation9';
[3]=>
string(45) "私はガラスを食べられますfile2.tmp"
}
-===DONE===
delete_files($dir, 2);
?>
-===DONE===
--CLEAN--
<?php
$dir = __DIR__ . '/scandir_variation9';
[3]=>
string(9) "file2.tmp"
}
-===DONE===
echo shell_exec("$php -n $test_file");
?>
-===DONE===
--EXPECTF--
string(%d) "%sbug74589_新建文件夹"
string(%d) "%sbug74589_新建文件夹%etest.php"
bool(true)
-===DONE===
--CLEAN--
<?php
$item = "bug74589_新建文件夹"; // utf-8 string
echo basename("y:file.txt", ".txt") . "\n";
echo basename("notdriveletter:file.txt") . "\n";
?>
-==DONE==
--EXPECT--
file.txt
file.txt
file
notdriveletter:file.txt
-==DONE==
echo basename("a:\\b:\\c:d:hello\\world:c:\$DATA") . "\n";
echo basename("a:\\b:\\c:d:hello\\d:world:c:\$DATA") . "\n";
?>
-==DONE==
--EXPECT--
y
y
world:my.stream:$DATA
world:c:$DATA
world:c:$DATA
-==DONE==
/* This has to behave same way on both 64- and 32-bits. */
file_put_contents('C:\Program Files\myfile.txt', 'hello');
?>
-==DONE==
--EXPECTF--
Warning: file_put_contents(C:\Program Files\myfile.txt): failed to open stream: Permission denied in %sbug47517.php on line %d
-==DONE==
var_dump(file_get_contents($tmp_empty_file, NULL, NULL, NULL, 10));
unlink($tmp_empty_file);
?>
-==DONE==
--EXPECT--
string(0) ""
-==DONE==
$fd = fopen("php://memory", "w+");
var_dump(ftruncate($fd, -1));
?>
-==DONE==
--EXPECTF--
Warning: ftruncate(): Negative size is not supported in %s%ebug71882.php on line %d
bool(false)
-==DONE==
unlink($fl);
?>
-==DONE==
--EXPECTF--
X-Powered-By: PHP/%s
Content-type: text/html; charset=UTF-8
hello
-==DONE==
}
?>
-===DONE===
--EXPECT--
ok
ok
ok
ok
ok
-===DONE===
?>
-==DONE==
--CLEAN--
<?php
$d = __DIR__;
[strlen] => 261
[result] => ok
)
-==DONE==
var_dump(chmod($filename, 0777));
?>
-===DONE===
--EXPECTF--
*** Testing chmod() : error conditions ***
Warning: chmod(): No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(fstat($h));
closedir($h);
?>
-===DONE===
--EXPECT--
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing dirname() : basic functionality ***
string(0) ""
string(14) " c:\test\adir"
string(1) "\"
string(1) "\"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing dirname() : basic functionality ***
string(0) ""
string(1) "."
string(1) "/"
string(1) "/"
-===DONE===
var_dump(strlen($s));
}
?>
-===DONE===
--EXPECT--
OK
-===DONE===
}
fclose($stream);
?>
-===DONE===
--EXPECT--
Array
(
[0] => \\\line1
line2\\\
)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing file_get_contents() : variation ***
File in include path
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing file_get_contents() : variation ***
File in script location
-===DONE===
}
?>
-===Done===
--EXPECTF--
*** Testing file_get_contents() : variation ***
Warning: file_get_contents(php/php): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===Done===
?>
-===DONE===
--EXPECT--
*** Testing file_put_contents() : variation ***
int(25)
The first string to write, followed by this
25
The first string to write
-===DONE===
unlink($filename);
?>
-===DONE===
--EXPECT--
*** Testing file_put_contents() : usage variation ***
--undefined var--
--unset var--
-===DONE===
}
?>
-===DONE===
--EXPECT--
File in include path
File in include path
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
File written in working directory
File written in working directory
File written in working directory
File written in working directory
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing file_put_contents() : variation ***
File in include path. This was appended
File in include path. This was appended
-===DONE===
};
?>
-===Done===
--EXPECTF--
*** Testing file_put_contents() : usage variation ***
Warning: file_put_contents(php/php): failed to open stream: %s in %s on line %d
Failed to write data to: php/php
-===Done===
echo "-- Checking for char --\n";
print( filetype("/dev/null") )."\n";
?>
-===DONE===
--EXPECT--
-- Checking for char --
char
-===DONE===
echo "-- Checking for block --\n";
print( filetype("/dev/ram0") )."\n";
?>
-===DONE===
--EXPECT--
-- Checking for block --
block
-===DONE===
);
?>
-===DONE===
--EXPECTF--
string(%d) "%stututu"
resource(%s) of type (Unknown)
int(0)
string(10) "helloworld"
bool(true)
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing fopen() : variation ***
file not opened for read
Warning: fclose() expects parameter 1 to be resource, bool given in %s on line %d
-===DONE===
rmdir('c:\\'.$rootdir);
?>
-===DONE===
--EXPECTF--
*** Testing fopen() : variation ***
file not opened for read
Warning: fclose() expects parameter 1 to be resource, bool given in %s on line %d
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
created in working dir
Not created in script dir
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing fopen() : variation ***
Created in correct location
Created in correct location
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing fopen() : variation ***
--- READ: file://fopen14.tmpDir\fopen_variation14.tmp ---
test passed
--- WRITE: file:///%s/fopen14.tmpDir/fopen_variation14.tmp ---
test passed
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing fopen() : variation ***
--- READ: file://fopen14.tmpDir/fopen_variation14.tmp ---
test passed
--- WRITE: file:///%s/fopen14.tmpDir/fopen_variation14.tmp ---
test passed
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing fopen() : variation ***
--- READ: file://fopen15.tmpDir\fopen_variation15.tmp ---
test passed
--- WRITE: file:///%s/fopen15.tmpDir/fopen_variation15.tmp ---
test passed
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing fopen() : variation ***
--- READ: file://fopen15.tmpDir/fopen_variation15.tmp ---
test passed
--- WRITE: file:///%s/fopen15.tmpDir/fopen_variation15.tmp ---
test passed
-===DONE===
rmdir($extraDir);
}
?>
-===DONE===
--EXPECT--
Not created in dir1
found file - not in dir1
Not created in dir1
found file - not in dir1
-===DONE===
rmdir($extraDir);
}
?>
-===DONE===
--EXPECT--
Not created in dir1
found file for reading
Not created in dir1
found file for reading
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing fopen() : variation ***
*** testing reading of links ***
soft link:Goodbye World
hard link:Goodbye World
link of link:Goodbye World
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing include path ---
in dir1
in working dir
in script dir
-===DONE===
unlink($absfile);
unlink($relfile);
?>
-===DONE===
--EXPECT--
*** Testing fopen() : variation ***
This is an absolute file
This is a relative file
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
created in working dir
Not created in dir1
created in working dir
Not created in dir1
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing include path ---
in dir1
in working dir
in script dir
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
created in working dir
Not created in dir1
created in working dir
Not created in dir1
-===DONE===
@unlink($file);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
$list = array (
0 => 'aaa,bbb',
18 => '"\\"","aaa"',
19 => '"\\""",aaa',
);
-===DONE===
@unlink($file);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
$list = array (
0 => 'aaa,bbb',
18 => '"/"","aaa"',
19 => '"/""",aaa',
);
-===DONE===
echo stream_get_contents($stream);
fclose($stream);
?>
-===DONE===
--EXPECT--
\
"\"""
-===DONE===
var_dump(fstat( $fp ) );
fclose($fp);
?>
-===DONE===
--EXPECTF--
array(26) {
[0]=>
["blocks"]=>
int(%i)
}
-===DONE===
?>
-===DONE===
--EXPECT--
PASSED: all elements are the same
-===DONE===
var_dump(empty(ini_get('open_basedir')));
?>
-==DONE==
--EXPECT--
array(0) {
}
array(0) {
}
bool(true)
-==DONE==
var_dump($path == ini_get('open_basedir'));
?>
-==DONE==
--EXPECT--
array(0) {
}
array(0) {
}
bool(true)
-==DONE==
var_dump('/tmp' == ini_get('open_basedir'));
?>
-==DONE==
--EXPECT--
bool(false)
bool(false)
bool(false)
bool(false)
bool(true)
-==DONE==
var_dump('c:\\windows' == ini_get('open_basedir'));
?>
-==DONE==
--EXPECT--
array(0) {
}
array(0) {
}
bool(true)
-==DONE==
var_dump( filegroup( $symlink ) === $gid );
?>
-===DONE===
--CLEAN--
<?php
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump( fileowner( $symlink ) === $uid );
?>
-===DONE===
--CLEAN--
<?php
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump( lchown( $filename, -5 ) );
?>
-===DONE===
--CLEAN--
<?php
Warning: lchown(): %r(Operation not permitted|Invalid argument)%r in %s on line %d
bool(false)
-===DONE===
"rdev", "size", "atime", "mtime", "blksize", "blocks");
var_dump( compare_stats($old_stat, $new_stat, $keys_to_compare) );
?>
-===Done===
--CLEAN--
<?php
$file_path = __DIR__;
bool(true)
bool(true)
bool(true)
-===Done===
rmdir($workDir);
?>
-===DONE===
--EXPECTF--
*** Testing mkdir() : variation ***
-- creating mkdirVar5.tmp\aSubDir --
Directory created
-- creating /%s/mkdirVar5.tmp/aSubDir --
Directory created
-===DONE===
rmdir($workDir);
?>
-===DONE===
--EXPECTF--
*** Testing mkdir() : variation ***
-- creating mkdirVar5.tmp/aSubDir --
Directory created
-- creating %s//mkdirVar5.tmp//aSubDir --
Directory created
-===DONE===
unlink($output_file);
?>
-===DONE===
--EXPECT--
*** Testing parse_ini_file() : variation ***
array(2) {
string(9) "different"
}
}
-===DONE===
var_dump($a);
unlink($output_file);
?>
-===DONE===
--EXPECT--
*** Testing parse_ini_file() : variation ***
array(8) {
string(0) ""
}
}
-===DONE===
var_dump(parse_ini_file($iniFile));
?>
-===Done===
--CLEAN--
<?php
["docref_ext"]=>
string(5) ".html"
}
-===Done===
?>
-===DONE===
--EXPECTF--
*** Testing pathinfo() : usage variation ***
array(4) {
string(6) "inet.h"
string(17) "/usr/include/arpa"
string(17) "/usr/include/arpa"
-===DONE===
};
?>
-===Done===
--EXPECTF--
*** Testing readfile() : variation ***
-- Filename: php/php --
Warning: readfile(php/php): failed to open stream: No such file or directory in %s on line %d
-===Done===
}
?>
-===DONE===
--EXPECT--
*** Testing readfile() : variation ***
File in include path
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing readfile() : variation ***
File in script location
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing realpath() : variation ***
--\tmp\--
bool(false)
-===DONE===
var_dump( compare_stats($old_stat, $new_stat, $keys_to_compare) );
?>
-===Done===
--CLEAN--
<?php
unlink(__DIR__."/rename_basic_new.tmp");
bool(false)
bool(true)
bool(true)
-===Done===
rmdir($workDir);
?>
-===DONE===
--EXPECTF--
*** Testing rmdir() : variation ***
-- removing rmdirVar3.tmp\aSubDir --
Directory removed
-- removing /%s/rmdirVar3.tmp/aSubDir --
Directory removed
-===DONE===
rmdir($workDir);
?>
-===DONE===
--EXPECTF--
*** Testing rmdir() : variation ***
-- removing rmdirVar3.tmp/aSubDir --
Directory removed
-- removing %s//rmdirVar3.tmp//aSubDir --
Directory removed
-===DONE===
var_dump(stream_get_contents($file));
?>
-===DONE===
--EXPECT--
string(11) "hello world"
string(11) "hello world"
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
array(7) {
["base64"]=>
string(34) "data://text/plain;foo=bar;bar=baz,"
}
string(3) "bar"
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
string(12) "A brief note"
string(40) "select_vcount,fcol_from_fieldtable/local"
string(13) "foobar foobar"
bool(true)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
string(5) ";test"
string(4) "test"
bool(false)
string(5) "Hello"
string(3) "a,b"
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
string(12) "A brief note"
string(40) "select_vcount,fcol_from_fieldtable/local"
bool(false)
string(5) "Hello"
string(3) "a,b"
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
file_get_contents() expects parameter 1 to be a valid path, string given
file_get_contents() expects parameter 1 to be a valid path, string given
Warning: file_get_contents(data:;base64,#Zm9vYmFyIGZvb2Jhc=): failed to open stream: rfc2397: unable to decode in %sstream_rfc2397_006.php on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
===data:,012345===
int(0)
int(-1)
bool(false)
bool(false)
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing touch() : variation ***
PASSED: touchVar5.tmp//aSubDirOrFile - touched
--- testing %s//touchVar5.tmp//aSubDirOrFile ---
PASSED: %s//touchVar5.tmp//aSubDirOrFile - touched
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing touch() : variation ***
PASSED: touchVar5.tmp//aSubDirOrFile - touched
--- testing /%s//touchVar5.tmp//aSubDirOrFile ---
PASSED: /%s//touchVar5.tmp//aSubDirOrFile - touched
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing touch() : variation ***
PASSED: %s\\touchVar5.tmp\\aSubDirOrFile - touched
--- testing /%s/touchVar5.tmp/aSubDirOrFile ---
PASSED: /%s/touchVar5.tmp/aSubDirOrFile - touched
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing unlink() : variation ***
-- unlinking soft link unlinkVar10.tmp/subDir.tmp --
--- try to unlink a directory ---
Warning: unlink(unlinkVar10.tmp/linkme.tmp): %s in %s on line %d
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
*** Testing unlink() : variation: contexts and relative files ***
subdir/testfile.txt exists
bool(true)
subdir/testfile.txt doesn't exist
-===DONE===
}
}
?>
-===DONE===
--EXPECTF--
*** Testing unlink() : variation ***
-- removing unlinkVar8.tmp/file.tmp --
file removed
-- removing %s//unlinkVar8.tmp//file.tmp --
file removed
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing unlink() : variation ***
-- removing unlinkVar8.tmp/file.tmp --
file unlinked
-- unlinking hard link /%s//unlinkVar8.tmp//file.tmp --
file unlinked
-===DONE===
rmdir($workDir);
?>
-===DONE===
--EXPECTF--
*** Testing unlink() : variation ***
-- removing unlinkVar9.tmp\file.tmp --
file removed
-- removing /%s/unlinkVar9.tmp/file.tmp --
file removed
-===DONE===
rmdir($prefix);
?>
-===DONE===
--EXPECT--
Returned (a)
Encoding: ASCII
Returned (王)
Encoding: UTF-8
-===DONE===
rmdir($prefix);
?>
-===DONE===
--EXPECTF--
bool(true)
string(%d) "%sa"
bool(true)
string(%d) "%s汚れて掘る"
bool(true)
-===DONE===
rmdir($prefix);
?>
-===DONE===
--EXPECT--
testBug54977
windows_mb_path
汚れて掘る.test
王
王.test
-===DONE===
rmdir($prefix);
?>
-===DONE===
--EXPECTF--
Active code page: 65001
getting basename of %s\ソフト
Active code page: %d
bool(true)
bool(true)
-===DONE===
var_dump(unlink($fnw));
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\š.txt"
Active code page: %d
bool(true)
-===DONE===
set_active_cp($old_cp);
?>
-===DONE===
--EXPECTF--
Active code page: 65001
filetype()[dir ] == is_dir()[dir ] -> OK: .
filetype()[dir ] == is_dir()[dir ] -> OK: 多国語
filetype()[dir ] == is_dir()[dir ] -> OK: 表
Active code page: %d
-===DONE===
rmdir($prefix);
?>
-===DONE===
--EXPECTF--
Active code page: 65001
getting basename of %s\ı
string(%d) "%s\ı"
Active code page: %d
bool(true)
-===DONE===
remove_data("bug71509");
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
-===DONE===
var_dump($s, @stat($s));
?>
-===DONE===
--EXPECTF--
string(271) "%s"
bool(false)
-===DONE===
rmdir($d0);
rmdir($prefix);
?>
-===DONE===
--EXPECTF--
string(4) "òåñò"
bool(true)
string(8) "code.php"
string(8) "test.txt"
string(8) "òàñò.txt"
-===DONE===
chdir($old_cwd);
?>
-===DONE===
--CLEAN--
<?php
$dir_basename = "тест";
string(8) "code.php"
string(8) "test.txt"
string(12) "таст.txt"
-===DONE===
} while (__DIR__ != $dir);*/
?>
-==DONE==
--EXPECTF--
string(%d) "%shello.txt"
bool(false)
-==DONE==
remove_data("file_big5");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(%d) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_big5");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s´ú¸Õ¦h¦r¸`¸ô®|5\´ú¸Õ¦h¦r¸`¸ô®|4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_big5");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s測試多字節路徑25"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_big5");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(%d) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_big5");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\測試多字節路徑5\測試多字節路徑4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_big5");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\測試多字節路徑25"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1250");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1250");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\šđčćž_ŠĐČĆŽ42\šđčćž_ŠĐČĆŽ4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1250");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\šđčćž_ŠĐČĆŽ33"
Active code page: %d
-===DONE===
remove_data("file_cp1250");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1250");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\Árvíztűrő tükörfúrógép42\Árvíztűrő tükörfúrógép4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1250");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\Árvíztűrő tükörfúrógép33"
Active code page: %d
-===DONE===
remove_data("file_cp1251");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(35) "opened an utf8 filename for reading"
bool(true)
-===DONE===
remove_data("dir_cp1251");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\ïðèâåò3\ïðèâåò4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1251");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\ïðèâåò7"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1251");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(35) "opened an utf8 filename for reading"
bool(true)
-===DONE===
remove_data("dir_cp1251");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\привет3\привет4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1251");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\привет7"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1251");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(35) "opened an utf8 filename for reading"
bool(true)
-===DONE===
remove_data("dir_cp1251");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\привет3\привет4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1251");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\привет7"
Active code page: %d
bool(true)
-===DONE===
remove_data("file");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\gefäß"
bool(true)
bool(true)
gefäß
-===DONE===
remove_data("file_cp1252");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(%d) "hallo
"
bool(true)
-===DONE===
remove_data("dir_cp1252");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\tschüß3\tschüß4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1252");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\tschüß7"
Active code page: %d
bool(true)
-===DONE===
remove_data("file2_cp1252");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(4) "hola"
bool(true)
-===DONE===
remove_data("dir2_cp1252");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\Voláçao3\Voláçao4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir2_cp1252");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\Voláçao7"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp1253");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1253");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\äéáäñïìÞ äïêéìÞò42\äéáäñïìÞ äïêéìÞò4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1253");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\äéáäñïìÞ äïêéìÞò33"
Active code page: %d
-===DONE===
remove_data("file_cp1253");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1253");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\διαδρομή δοκιμής42\διαδρομή δοκιμής4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1253");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\διαδρομή δοκιμής33"
Active code page: %d
-===DONE===
remove_data("file_cp1254");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1254");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\çokbaytlý iþleri42\çokbaytlý iþleri4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1254");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\çokbaytlý iþleri33"
Active code page: %d
-===DONE===
remove_data("file_cp1254");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\çokbaytlý iþleri"
bool(true)
bool(true)
çokbaytlý iþleri
-===DONE===
remove_data("file_cp1254");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1254");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\çokbaytlı işleri42\çokbaytlı işleri4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1254");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\çokbaytlı işleri33"
Active code page: %d
-===DONE===
remove_data("file_cp1254");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\çokbaytlı işleri"
bool(true)
bool(true)
çokbaytlı işleri
-===DONE===
remove_data("file_cp1255");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1255");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\ëììéí îøåáéí42\ëììéí îøåáéí4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1255");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\ëììéí îøåáéí33"
Active code page: %d
-===DONE===
remove_data("file_cp1255");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1255");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%s) "%s\כללים מרובים42\כללים מרובים4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1255");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\כללים מרובים33"
Active code page: %d
-===DONE===
remove_data("file_cp1256");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1256");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\ãÓÇÑ ãÊÚÏÏ ÇáÈÇíÊ ÇÎÊÈÇÑ42\ãÓÇÑ ãÊÚÏÏ ÇáÈÇíÊ ÇÎÊÈÇÑ4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1256");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\ãÓÇÑ ãÊÚÏÏ ÇáÈÇíÊ ÇÎÊÈÇÑ33"
Active code page: %s
-===DONE===
remove_data("file_cp1256");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp1256");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\مسار متعدد البايت اختبار42\مسار متعدد البايت اختبار4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp1256");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\مسار متعدد البايت اختبار33"
Active code page: %s
-===DONE===
}
?>
-===DONE===
--EXPECTF--
Active code page: %d
getting basename of %sà»ç¹á¿éÁ·Õè·´Êͺ1.txt
string(%d) "%sà»ç¹á¿éÁ·Õè·´Êͺ8 10.txt"
Active code page: %d
string(6) "hello8"
-===DONE===
remove_data("file_cp874");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\à»ç¹á¿éÁ·Õè·´Êͺ11"
bool(true)
bool(true)
à»ç¹á¿éÁ·Õè·´Êͺ11
-===DONE===
}
?>
-===DONE===
--EXPECTF--
Active code page: %d
getting basename of %sเป็นแฟ้มที่ทดสอบ1.txt
string(%d) "%sเป็นแฟ้มที่ทดสอบ8 10.txt"
Active code page: %d
string(6) "hello8"
-===DONE===
remove_data("file_cp874");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\เป็นแฟ้มที่ทดสอบ11"
bool(true)
bool(true)
เป็นแฟ้มที่ทดสอบ11
-===DONE===
remove_data("file_cp932");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp932");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\\83e\83X\83g\83}\83\8b\83`\83o\83C\83g\81E\83p\83X42\\83e\83X\83g\83}\83\8b\83`\83o\83C\83g\81E\83p\83X4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp932");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\\83e\83X\83g\83}\83\8b\83`\83o\83C\83g\81E\83p\83X33"
Active code page: %d
-===DONE===
remove_data("file_cp932");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\\83e\83X\83g\83}\83\8b\83`\83o\83C\83g\81E\83p\83X77"
bool(true)
bool(true)
\83e\83X\83g\83}\83\8b\83`\83o\83C\83g\81E\83p\83X77
-===DONE===
remove_data("file_cp932");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp932");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\テストマルチバイト・パス42\テストマルチバイト・パス4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_cp932");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\テストマルチバイト・パス33"
Active code page: %d
-===DONE===
remove_data("file_cp936");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(%d) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp936");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\\9cyÔ\87¶à×Ö¹\9d·\8f½5\\9cyÔ\87¶à×Ö¹\9d·\8f½4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp936");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\\9cyÔ\87¶à×Ö¹\9d·\8f½25"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp936");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(%d) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_cp936");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\測試多字節路徑5\測試多字節路徑4"
Active code page: %d
bool(true)
-===DONE===
remove_data("file_cp936");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
string(%d) "%s\測試多字節路徑25"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_mb");
?>
-===DONE===
--EXPECTF--
Active code page: 65001
bool(true)
string(%d) "%s\テストマルチバイト・パス42"
bool(true)
Active code page: %d
-===DONE===
remove_data("file_eucjp");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_eucjp");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\テストマルチバイト・パス42\テストマルチバイト・パス4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_eucjp");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\テストマルチバイト・パス33"
Active code page: %d
-===DONE===
remove_data("file_kartuli");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
string(37) "reading file wihh multibyte filename
"
bool(true)
-===DONE===
remove_data("dir_kartuli");
?>
-===DONE===
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s\ქართველები42\ქართველები4"
Active code page: %d
bool(true)
-===DONE===
remove_data("dir_kartuli");
?>
-===DONE===
--EXPECTF--
resource(%d) of type (stream)
int(25)
bool(true)
string(%d) "%s\ქართველები33"
Active code page: %d
-===DONE===
remove_data("file_kartuli");
?>
-===DONE===
--EXPECTF--
string(%d) "%s\ქართველები55"
bool(true)
bool(true)
ქართველები55
-===DONE===
var_dump(file_exists(realpath(__DIR__) . DIRECTORY_SEPARATOR . $s));
?>
-===DONE===
--EXPECTF--
%d%d%d%d
%s\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\
bool(true)
bool(true)
bool(false)
-===DONE===
var_dump(file_exists(realpath(__DIR__) . DIRECTORY_SEPARATOR . $s));
?>
-===DONE===
--EXPECTF--
%d%d%d%d
%s\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\
bool(true)
string(5) "hello"
bool(false)
-===DONE===
var_dump(file_exists(realpath(__DIR__) . DIRECTORY_SEPARATOR . $s));
?>
-===DONE===
--EXPECTF--
%d%d%d%d
%s\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxü\
int(5)
string(5) "hello"
bool(false)
-===DONE===
var_dump(rmdir($dest_dir));
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
bool(true)
bool(true)
bool(true)
-===DONE===
unlink($testFile);
?>
-===DONE===
--EXPECT--
Generating a file with a path length of 259 characters...
Opening file... OK
-===DONE===
} while ($p != $base);
?>
-===DONE===
--EXPECTF--
string(%d) "%s\dev\http\tproj\app\cache\dev_old\annotations\72\5b53796d666f6e795c42756e646c655c5477696742756e646c655c436f6e74726f6c6c65725c457863657074696f6e436f6e74726f6c6c657223676574416e64436c65616e4f7574707574427566666572696e67405b416e6e6f745d5d5b.doctrinecache.data"
bool(true)
bool(true)
bool(true)
bool(true)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
string(251) "%s"
string(1884) "%s"
bool(true)
int(5)
string(5) "hello"
-===DONE===
remove_data("mb_names");
?>
-===DONE===
--EXPECTF--
Active code page: 65001
filename: . : filetype: dir
filename: 測試多字節路徑 : filetype: file
filename: 測試多字節路徑5 : filetype: dir
Active code page: %d
-===DONE===
remove_data("file2_mb");
?>
-===DONE===
--EXPECTF--
Active code page: 65001
bool(true)
bool(true)
bool(true)
Active code page: %d
-===DONE===
fclose( $fp );
?>
-===DONE===
--CLEAN--
<?php
bool(true)
Grfgvat gur ebg13 svygre juvpu fuvsgf fbzr guvatf nebhaq.
add some more un-filtered foobar
-===DONE===
fclose( $fp );
?>
-===DONE===
--CLEAN--
<?php
Warning: stream_filter_remove(): Invalid resource given, not a stream filter in %s on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
This is an exception from bar(first try).
This is an exception from bar(second try).
-===DONE===
TestClass::whee5();
?>
-===DONE===
--EXPECT--
TestClass::test()
TestClass::test()
TestClass::test()
TestClass::test()
TestClass::test()
-===DONE===
new Derived_6('6');
?>
-===DONE===
--EXPECT--
Base::__construct(1)
Base::__construct(2)
Base::__construct(4)
Base::__construct(5)
Base::__construct(6)
-===DONE===
phpinfo(INFO_VARIABLES);
?>
-==DONE==
--EXPECTF--
phpinfo()
PHP Variables
%A
-==DONE==
output_add_rewrite_var('bar', 'baz');
?>
<form action="http://example.com/"></form>
-===DONE===
--EXPECT--
<form action="http://example.com/"></form>
-===DONE===
test('test2');
?>
-===DONE===
--EXPECTF--
Direct Call
string(5) "test1" refcount(%d)
string(5) "test2" refcount(%d)
User Func
string(5) "test2" refcount(%d)
-===DONE===
$o->test();
?>
-===DONE===
--EXPECTF--
parent|who
B
O
$this|B::who
call_user_func() expects parameter 1 to be a valid callback, class 'P' is not a subclass of 'B'
-===DONE===
$iterator++;
};
?>
-===Done===
--EXPECT--
*** Testing escapeshellarg() : usage variations ***
-- Iteration 20 --
string(2) """"
-===Done===
$iterator++;
};
?>
-===Done===
--EXPECT--
*** Testing escapeshellarg() : usage variations ***
-- Iteration 20 --
string(2) "''"
-===Done===
}
?>
-===DONE===
--EXPECT--
*** Testing floatval() with valid float values ***
-- Iteration : -.5e+7 --
float(-5000000)
-===DONE===
var_dump( doubleval($type) );
}
?>
-===DONE===
--EXPECTF--
Notice: A non well formed numeric value encountered in %s on line %d
-- Iteration : null --
float(0)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing get_defined_constants() : basic functionality ***
string(5) "array"
array(0) {
}
TEST PASSED
-===DONE===
f1();
?>
-===DONE===
--EXPECT--
Simple testcase for get_defined_vars() function
["b1"]=>
bool(true)
}
-===DONE===
var_dump(get_extension_funcs("foo"));
?>
-===DONE===
--EXPECT--
Simple testcase for get_extension_funcs() function
string(5) "array"
bool(true)
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing get_include_path()
string(1) "."
PASSED
-===DONE===
var_dump(get_included_files());
?>
-===DONE===
--EXPECTF--
*** Testing get_included_files()
[3]=>
string(%d) "%sget_included_files_inc3.inc"
}
-===DONE===
var_dump(get_loaded_extensions());
?>
-===DONE===
--EXPECTF--
*** Testing get_loaded_extensions() : basic functionality ***
Get loaded extensions
array(%d) {
%a
}
-===DONE===
var_dump(get_resource_type($res));
?>
-===DONE===
--EXPECT--
*** Testing get_resource_type() : basic functionality ***
string(6) "stream"
-===DONE===
echo "User time used (seconds) " . $dat["ru_utime.tv_sec"] . "\n";
echo "User time used (microseconds) " . $dat["ru_utime.tv_usec"] . "\n";
?>
-===DONE===
--EXPECTF--
Simple testcase for getrusage() function
User time used (seconds) %d
User time used (microseconds) %d
-===DONE===
};
?>
-===DONE===
--EXPECTF--
*** Testing intval() : usage variation ***
--unset var--
int(0)
-===DONE===
check_iscallable($defined_functions);
?>
-===DONE===
--EXPECT--
*** Testing is_callable() on defined functions ***
-- Iteration 1 --
bool(true)
bool(true)
Hello_World
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing is_callable() on objects ***
object_class::foo1
bool(false)
object_class::foo1
-===DONE===
check_iscallable($undef_functions);
?>
-===DONE===
--EXPECT--
*** Testing is_callable() on undefined functions ***
-- Iteration 1 --
bool(false)
bool(false)
"echo()"
-===DONE===
fclose($file_handle);
?>
-===DONE===
--EXPECTF--
*** Testing is_callable() on invalid function names ***
-- Iteration 1 --
bool(false)
bool(false)
Resource id #%d
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing is_resource() : basic functionality ***
Resource type..var_dump after file close returns
resource(%d) of type (Unknown)
Resource type..after file close is_resource() returns FALSE
-===DONE===
echo "Object test: " . (isset($obj) ? "YES": "NO") . "\n";
echo "Resource test: " . (isset($res) ? "YES": "NO") . "\n";
?>
-===DONE===
--EXPECT--
*** Testing isset() : basic functionality ***
Integer test: YES
Null test: NO
Object test: NO
Resource test: NO
-===DONE===
var_dump(isset($var, $var[1]));
?>
-===DONE===
--EXPECT--
*** Testing isset() : basic functionality ***
Test multiple scalar variables in a group
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump($string)
?>
-===DONE===
--EXPECT--
*** Testing ob_get_flush() : basic functionality ***
testing ob_get_flush() with some
array(0) {
}
string(0) ""
-===DONE===
var_dump( ob_get_flush() );
?>
-===DONE===
--EXPECTF--
*** Testing ob_get_flush() : error conditions ***
Notice: ob_get_flush(): failed to delete and flush buffer. No buffer to delete or flush in %s on line %d
bool(false)
-===DONE===
dump_string_length( null );
?>
-===DONE===
--EXPECTF--
*** Testing ob_get_length() : basic functionality ***
bool(false)
int(15)
int(0)
int(0)
-===DONE===
echo $str1, $str2;
?>
-===DONE===
--EXPECT--
*** Testing ob_start() : closures as output handlers ***
Output (1): Output (2): Test
With newlines
Output (2): Test
With newlines
-===DONE===
var_dump($s);
?>
-==DONE==
--EXPECT--
array(1) {
["foo"]=>
string(2) "42"
}
}
-==DONE==
var_dump(php_uname('m'));
?>
-===DONE===
--EXPECTF--
*** Testing php_uname() - basic test
string(%d) "%s"
string(%d) "%s"
string(%d) "%s"
string(%d) "%s"
-===DONE===
var_dump( php_uname('z') == php_uname('z') );
?>
-===DONE===
--EXPECTF--
*** Testing php_uname() - error test
-- Testing php_uname() function with invalid mode --
bool(true)
-===DONE===
echo $out;
?>
-==DONE==
--EXPECTF--
array(4) {
[0]=>
[3]=>
string(14) "карамба"
}
-==DONE==
echo $out;
?>
-==DONE==
--EXPECTF--
array(4) {
[0]=>
[3]=>
string(14) "карамба"
}
-==DONE==
var_dump(putenv('FOO=°¡a°¡°¡°¡°¡'), getenv("FOO"));
?>
-===DONE===
--EXPECT--
bool(true)
string(2) "°¡"
string(9) "°¡a°¡°¡°¡"
bool(true)
string(11) "°¡a°¡°¡°¡°¡"
-===DONE===
var_dump(putenv('FOO=啊a啊啊啊啊'), getenv("FOO"));
?>
-===DONE===
--EXPECT--
bool(true)
string(3) "啊"
string(13) "啊a啊啊啊"
bool(true)
string(16) "啊a啊啊啊啊"
-===DONE===
echo "TEST FAILED - time is ${time} secs and sleep was ${sleeptime} secs\n";
}
?>
-===DONE===
--EXPECTF--
*** Testing sleep() : basic functionality ***
Thread slept for %f seconds
Return value: 0
TEST PASSED
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing uniqid() : basic functionality ***
string(23) "%s.%s"
string(13) "%s"
-===DONE===
echo "TEST FAILED: $summary";
}
?>
-===DONE===
--EXPECTF--
*** Testing usleep() : basic functionality ***
TEST PASSED: Thread slept for %f micro-seconds
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with integer values ***
2147483647
2147483647
string(10) "2147483647"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with integer values ***
2147483647
2147483647
string(10) "2147483647"
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with valid boolean values ***
false
string(5) "false"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with valid float values ***
3.4000000000000001E-33
string(22) "3.4000000000000001E-33"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with valid strings ***
'8'
string(3) "'8'"
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with valid arrays ***
1 => 'test',
)"
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with valid objects ***
string(36) "concreteClass::__set_state(array(
))"
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECT--
*** Testing var_export() with valid null values ***
NULL
string(4) "NULL"
-===DONE===
var_export($obj, true);
?>
-===DONE===
--EXPECTF--
Warning: var_export does not handle circular references in %s on line 10
-===DONE===
var_export($a, true);
?>
-===DONE===
--EXPECTF--
Warning: var_export does not handle circular references in %s on line 9
-===DONE===
http_server_kill($pid);
var_dump($f);
?>
-==DONE==
--EXPECTF--
Warning: file_get_contents(http://127.0.0.1:22345/): failed to open stream: HTTP request failed! HTTP/1.0 404 Not Found%ain %s on line %d
bool(false)
-==DONE==
http_server_kill($pid);
?>
-==DONE==
--EXPECT--
string(0) ""
array(2) {
[1]=>
string(14) "Content-Length"
}
-==DONE==
http_server_kill($pid);
?>
-==DONE==
--EXPECT--
string(4) "Body"
array(3) {
[2]=>
string(12) "Some: Header"
}
-==DONE==
http_server_kill($pid);
?>
-==DONE==
--EXPECT--
string(4) "Body"
array(5) {
[4]=>
string(12) "Some: Header"
}
-==DONE==
http_server_kill($pid);
?>
-==DONE==
--EXPECTF--
Warning: file_get_contents(http://127.0.0.1:22348/): failed to open stream: HTTP request failed! HTTP/1.0 404 Not Found%a
bool(false)
[4]=>
string(12) "Some: Header"
}
-==DONE==
http_server_kill($pid);
?>
-==DONE==
--EXPECT--
string(4) "Body"
array(2) {
[1]=>
string(14) "Some: Header"
}
-==DONE==
http_server_kill($pid);
?>
-==DONE==
--EXPECT--
string(4) "Body"
array(2) {
[1]=>
string(0) ""
}
-==DONE==
var_dump(getimagesize(__DIR__ . '/bug71848.jpg', $info));
var_dump(array_keys($info));
?>
-===DONE===
--EXPECT--
array(7) {
[0]=>
[1]=>
string(4) "APP5"
}
-===DONE===
var_dump(getimagesize(FILENAME));
?>
-===DONE===
--EXPECTF--
Warning: getimagesize(): corrupt JPEG data: 3 extraneous bytes before marker in %s%ebug72278.php on line %d
array(7) {
["mime"]=>
string(10) "image/jpeg"
}
-===DONE===
var_dump( $info );
};
?>
-===DONE===
--EXPECTF--
*** Testing getimagesize() : basic functionality ***
}
array(0) {
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
APP1 - length: 1717; md5: 02cbf4ba6640c131422483138c968516
APP2 - length: 7275; md5: f5036ccca2031e8bf932bcbd4aca4355
APP13 - length: 42; md5: 2202998bd05e78bcb419f08c070d6f61
-===DONE===
var_dump($arr);
?>
-===DONE===
--EXPECT--
*** Testing getimagesize() : tiff_mm format ***
array(5) {
}
array(0) {
}
-===DONE===
};
?>
-===DONE===
--EXPECT--
*** Testing getimagesize() : usage variations ***
Error: 2 - Undefined variable: undefined_var
-- Arg value unset_var --
string(28) "4a46494600010201006000600000"
-===DONE===
var_dump( $info );
};
?>
-===DONE===
--EXPECTF--
*** Testing getimagesize() : variation ***
bool(false)
array(0) {
}
-===DONE===
var_dump( getimagesize(__DIR__."/test13pix.swf", $info) );
var_dump( $info );
?>
-===DONE===
--EXPECT--
*** Testing getimagesize() : variation ***
array(5) {
}
array(0) {
}
-===DONE===
var_dump( getimagesize(__DIR__."/test13pix.swf", $info) );
var_dump( $info );
?>
-===DONE===
--EXPECT--
*** Testing getimagesize() : basic functionality ***
array(5) {
}
array(0) {
}
-===DONE===
var_dump($arr);
?>
-===DONE===
--EXPECT--
*** Testing getimagesize() : wbmp format ***
array(5) {
}
array(0) {
}
-===DONE===
var_dump($arr);
?>
-===DONE===
--EXPECT--
*** Testing getimagesize() : xbm format ***
array(5) {
}
array(0) {
}
-===DONE===
$iterator++;
};
?>
-===DONE===
--EXPECT--
*** Testing image_type_to_mime_type() : usage variations ***
-- Iteration 12 --
string(24) "application/octet-stream"
-===DONE===
var_dump(image_type_to_mime_type($imagetype));
}
?>
-===DONE===
--EXPECTREGEX--
\*\*\* Testing image_type_to_mime_type\(\) : usage variations \*\*\*
-- Iteration 19 --
string\(24\) "application\/octet-stream"
-===DONE===
var_dump( image_type_to_mime_type(IMAGETYPE_ICO) );
var_dump( image_type_to_mime_type(IMAGETYPE_SWC) );
?>
-===DONE===
--EXPECT--
*** Testing image_type_to_mime_type() : usage variations ***
string(24) "image/vnd.microsoft.icon"
string(29) "application/x-shockwave-flash"
-===DONE===
unlink($outFile);
?>
-===DONE===
--EXPECT--
bool(true)
To: user@example.com
KHeaders
A Message
-===DONE===
unlink($outFile);
?>
-===DONE===
--EXPECTF--
*** Testing mail() : send email without additional headers ***
bool(true)
X-PHP-Originating-Script: %d:bug66535.php
A Message
-===DONE===
$message = "Line 1\r\nLine 2\r\nLine 3";
mail('user@example.com', 'My Subject', $message, "From: me@me.me");
?>
-===DONE===
--EXPECTREGEX--
.*
-===DONE===
unlink($outFile);
?>
-===DONE===
--EXPECT--
*** Testing mail() : send email without additional headers ***
bool(true)
Subject: Test Subject
A Message
-===DONE===
unlink($outFile);
?>
-===DONE===
--EXPECTF--
*** Testing mail() : send email without additional headers ***
bool(true)
X-PHP-Originating-Script: %d:bug69874_2.php
A Message
-===DONE===
mail('test@example.com', 'subject', 'message', 'From: lala@example.com', '')
);
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump(ezmlm_hash("foo@somewhere.com"));
?>
-===Done===
--EXPECTF--
*** Testing ezmlm_hash() : basic functionality ***
Deprecated: Function ezmlm_hash() is deprecated in %s on line %d
int(7)
-===Done===
unlink($outFile);
?>
-===DONE===
--EXPECT--
*** Testing mail() : basic functionality ***
-- All Mail Content Parameters --
Subject: Test Subject
A Message
-===DONE===
echo file_get_contents($outFile);
unlink($outFile);
?>
-===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
-- extra parameters --
%w3%wKHeaders
%w4%w
%w5%wA Message
-===DONE===
echo "-- failure --\n";
var_dump( mail($to, $subject, $message) );
?>
-===DONE===
--EXPECT--
*** Testing mail() : basic functionality ***
-- failure --
bool(false)
-===DONE===
var_dump( mail($to, $subject, $message) );
?>
-===DONE===
--EXPECT--
*** Testing mail() : basic functionality ***
-- failure --
bool(false)
-===DONE===
echo "-- failure --\n";
var_dump( mail($to, $subject, $message) );
?>
-===DONE===
--EXPECT--
*** Testing mail() : basic functionality ***
-- failure --
bool(false)
-===DONE===
@unlink($outFile);
?>
-===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
-- Valid Header --
HEAD2: b
A Message
-===DONE===
unlink($outFile);
?>
-===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
foo9: %&$#!
A Message
-===DONE===
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
--EXPECTF--
*** Testing mail() : basic functionality ***
Msg sent OK
Id of msg just sent is %d
.. delete it
TEST PASSED: Msgs sent and deleted OK
-===Done===
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
--EXPECTF--
*** Testing mail() : basic functionality ***
Msg sent OK
Id of msg just sent is %d
.. delete it
TEST PASSED: Msgs sent and deleted OK
-===Done===
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
--EXPECTF--
*** Testing mail() : basic functionality ***
Msg sent OK
Id of msg just sent is %d
.. delete it
TEST PASSED: Msgs sent and deleted OK
-===Done===
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
--EXPECTF--
*** Testing mail() : basic functionality ***
Msg sent OK
Id of msg just sent is %d
.. delete it
TEST PASSED: Msgs sent and deleted OK
-===Done===
$message = 'A Message';
var_dump( mail($to, $subject, $message) );
?>
-===DONE===
--EXPECT--
*** Testing mail() : variation ***
bool(false)
-===DONE===
unlink($outFile);
?>
-===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
bool(true)
%w2%wSubject: Test Subject
%w3%w
%w4%wA Message
-===DONE===
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
+===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
+===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
imap_close($imap_stream, CL_EXPUNGE);
?>
-===Done===
+===DONE===
--EXPECTF--
*** Testing mail() : basic functionality ***
var_dump($res);
}
?>
-===Done===
--EXPECT--
*** Testing abs() : basic functionality ***
int(23)
int(0)
int(1)
int(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
int(9223372036854775807)
int(9223372036854775807)
--- testing: -9.2233720368548E+18 ---
float(9.2233720368548E+18)
-===DONE===
fclose($fp);
?>
-===Done===
--EXPECT--
*** Testing abs() : usage variations ***
-- Iteration 16 --
abs() expects parameter 1 to be int or float, resource given
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(NAN)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(44.361419555836)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(NAN)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(44.361419555836)
float(-44.361419555836)
--- testing: -9.2233720368548E+18 ---
float(-44.361419555836)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807, 0 ---
float(1.5707963267949)
float(-0.78539816339745)
--- testing: -9.2233720368548E+18, -9223372036854775808 ---
float(-2.3561944901923)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(1.5707963267949)
float(-1.5707963267949)
--- testing: -9.2233720368548E+18 ---
float(-1.5707963267949)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(NAN)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing base_convert() : usage variations ***
Deprecated: Invalid characters passed for attempted conversion, these have been ignored in %s on line %d
string(1) "5"
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 0111111111111111111111111111111111111111111111111111111111111111 ---
int(9223372036854775807)
int(4294967295)
--- testing: 111111111111111111111111111111111 ---
int(8589934591)
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing bindec() : usage variations ***
-- Iteration 24 --
bindec() expects parameter 1 to be string, resource given
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing bindec() : usage variations ***
-- Iteration 24 --
bindec() expects parameter 1 to be string, resource given
-===Done===
mt_srand(0, MT_RAND_PHP);
var_dump(mt_rand(0,999999999), mt_rand(0,999));
?>
-===Done===
--EXPECT--
int(448865905)
int(592)
-===Done===
}
?>
-===Done===
--EXPECT--
*** Testing ceil() : basic functionality ***
float(0)
float(1)
float(0)
float(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(9.2233720368548E+18)
float(-9.2233720368548E+18)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECT--
*** Testing ceil() : usage variations ***
-- Iteration 16 --
ceil() expects parameter 1 to be int or float, resource given
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(0.0118000765128)
float(0.0118000765128)
--- testing: -9.2233720368548E+18 ---
float(0.0118000765128)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(INF)
float(INF)
--- testing: -9.2233720368548E+18 ---
float(INF)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
string(63) "111111111111111111111111111111111111111111111111111111111111111"
string(64) "1000000000000000000000000000000000000000000000000000000000000001"
--- testing: -9.2233720368548E+18 ---
string(64) "1000000000000000000000000000000000000000000000000000000000000000"
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing decbin() : usage variations ***
-- Iteration 27 --
string(%d) "%d"
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing decbin() : usage variations ***
-- Iteration 27 --
string(%d) "%d"
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
string(16) "7fffffffffffffff"
string(16) "8000000000000001"
--- testing: -9.2233720368548E+18 ---
string(16) "8000000000000000"
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing dechex() : usage variations ***
-- Iteration 27 --
string(%d) "%s"
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing dechex() : usage variations ***
-- Iteration 27 --
string(%d) "%s"
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
string(21) "777777777777777777777"
string(22) "1000000000000000000001"
--- testing: -9.2233720368548E+18 ---
string(22) "1000000000000000000000"
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing decoct() : usage variations ***
-- Iteration 27 --
string(%d) "%d"
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing decoct() : usage variations ***
-- Iteration 27 --
string(%d) "%d"
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(1.6097821017949E+17)
float(-1.6097821017949E+17)
--- testing: -9.2233720368548E+18 ---
float(-1.6097821017949E+17)
-===DONE===
};
?>
-===Done===
--EXPECT--
-- Iteration 1 --
float(22026.465794807)
-- Iteration 12 --
float(1)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(INF)
float(0)
--- testing: -9.2233720368548E+18 ---
float(0)
-===DONE===
$iterator++;
};
?>
-===Done===
--EXPECT--
*** Testing expm1() : basic functionality ***
-- Iteration 12 --
float(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(INF)
float(-1)
--- testing: -9.2233720368548E+18 ---
float(-1)
-===DONE===
};
?>
-===Done===
--EXPECT--
*** Testing floor() : basic functionality ***
-- floor --
float(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(9.2233720368548E+18)
float(-9.2233720368548E+18)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECT--
*** Testing floor() : usage variations ***
-- Iteration 16 --
floor() expects parameter 1 to be int or float, resource given
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807, 0 ---
float(NAN)
float(-0)
--- testing: -9.2233720368548E+18, -9223372036854775808 ---
float(-0)
-===DONE===
};
?>
-===Done===
--EXPECTF--
*** Testing hexdec() : basic functionality ***
-- hexdec --
int(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 7fffffffffffffff ---
int(9223372036854775807)
int(34359738367)
--- testing: fffffffff ---
int(68719476735)
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing hexdec() : usage variations ***
-- Iteration 26 --
hexdec() expects parameter 1 to be string, resource given
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing hexdec() : usage variations ***
-- Iteration 26 --
hexdec() expects parameter 1 to be string, resource given
-===Done===
}
}
?>
-===Done===
--EXPECTF--
*** Testing hypot() : basic functionality ***
Y: X:1 float(1)
Y: X: float(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807, 0 ---
float(9.2233720368548E+18)
float(1.3043817825333E+19)
--- testing: -9.2233720368548E+18, -9223372036854775808 ---
float(1.3043817825333E+19)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
bool(true)
bool(true)
--- testing: -9.2233720368548E+18 ---
bool(true)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
bool(false)
bool(false)
--- testing: -9.2233720368548E+18 ---
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
bool(false)
bool(false)
--- testing: -9.2233720368548E+18 ---
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(18.964889726831)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
?>
-===Done===
--EXPECT--
*** Testing log1p() : basic functionality ***
-- log1p --
float(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(43.668272375277)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(43.668272375277)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
var_dump($res);
}
?>
-===Done===
--EXPECTF--
*** Testing octdec() : basic functionality ***
int(1)
int(0)
int(0)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 777777777777777777777 ---
int(9223372036854775807)
int(34359738367)
--- testing: 777777777777 ---
int(68719476735)
-===DONE===
echo "\n\n";
}
?>
-===Done===
--EXPECT--
Base = 23
..... Exponent = 0 Result = 1
..... Exponent = 2147483647 Result = -INF
..... Exponent = -2147483648 Result = 0
-===Done===
var_dump(pow(-0.24, -$large_exp+1));
?>
-===Done===
--EXPECTF--
-- The following all result in INF --
float(INF)
-- The following all result in -INF --
float(-INF)
float(-INF)
-===Done===
echo "\n\n";
}
?>
-===Done===
--EXPECT--
Base = 23
..... Exponent = 0 Result = 1
..... Exponent = 2147483647 Result = -INF
..... Exponent = -2147483648 Result = 0
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807, 0 ---
int(1)
float(INF)
--- testing: -9.2233720368548E+18, -9223372036854775808 ---
float(0)
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing pow() : usage variations ***
-- Iteration 26 --
%s
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing pow() : usage variations ***
-- Iteration 26 --
%s
-===Done===
};
fclose($fp);
?>
-===Done===
--EXPECTF--
*** Testing pow() : usage variations ***
-- Iteration 26 --
%s
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(5.2846029059076E+20)
float(-5.2846029059076E+20)
--- testing: -9.2233720368548E+18 ---
float(-5.2846029059076E+20)
-===DONE===
}
}
?>
-===Done===
--EXPECT--
*** Testing round() : basic functionality ***
round: 123456789
...with precision -> float(234567890)
...with precision 1-> float(234567890)
...with precision -> float(234567890)
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(9.2233720368548E+18)
float(-9.2233720368548E+18)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
<?php
echo round(1.0, -2147483648), "\n";
?>
-===DONE===
--EXPECT--
0
-===DONE===
};
fclose($fp);
?>
-===Done===
--EXPECT--
*** Testing round() : usage variations ***
-- Iteration 26 --
round() expects parameter 1 to be int or float, resource given
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(0.99993037667344)
float(-0.99993037667344)
--- testing: -9.2233720368548E+18 ---
float(-0.99993037667344)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(INF)
float(-INF)
--- testing: -9.2233720368548E+18 ---
float(-INF)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(3037000499.976)
float(NAN)
--- testing: -9.2233720368548E+18 ---
float(NAN)
-===DONE===
}
?>
-===Done===
--EXPECTF--
*** Testing sqrt() : usage variations ***
float(4.7958315233127)
float(0)
float(1)
float(0)
-===Done===
var_dump(srand(false));
var_dump(srand(NULL));
?>
-===Done===
--EXPECT--
*** Testing srand() : basic functionality ***
NULL
NULL
NULL
NULL
-===Done===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(84.739)
float(-84.739)
--- testing: -9.2234E+18 ---
float(-84.739)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(1)
float(-1)
--- testing: -9.2233720368548E+18 ---
float(-1)
-===DONE===
$caps = get_browser($user_agent, true);
var_dump($caps['browser'], $caps['version']);
?>
-==DONE==
--EXPECT--
string(7) "OmniWeb"
string(3) "5.6"
-==DONE==
}
?>
-===DONE===
--EXPECT--
*** Testing get_browser() : basic functionality ***
array(35) {
["aolversion"]=>
string(1) "0"
}
-===DONE===
var_dump( get_browser( null, 'foobar' ) );
?>
-===DONE===
--EXPECTF--
*** Testing get_browser() : error functionality ***
array(34) {
Warning: get_browser(): HTTP_USER_AGENT variable is not set, cannot determine user agent name in %s on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing get_browser() : variation functionality: extra browser names ***
array(35) {
["aolversion"]=>
string(1) "0"
}
-===DONE===
echo "ok\n";
}
?>
-===DONE===
--EXPECT--
Test
ok
-===DONE===
echo "\n-- Testing closelog() function with Zero arguments --\n";
var_dump( closelog() );
?>
-===DONE===
--EXPECT--
*** Testing closelog() : basic functionality ***
-- Testing closelog() function with Zero arguments --
bool(true)
-===DONE===
echo gethostbyaddr("127.0.0.1")."\n";
?>
-===DONE===
--EXPECTF--
*** Testing gethostbyaddr() : basic functionality ***
%rloopback|localhost(\.localdomain)?|%s%r
-===DONE===
echo gethostbyname("localhost")."\n";
?>
-===DONE===
--EXPECT--
*** Testing gethostbyname() : basic functionality ***
127.0.0.1
-===DONE===
echo "*** Testing gethostbynamel() : basic functionality ***\n";
var_dump(gethostbynamel("localhost"));
?>
-===DONE===
--EXPECTF--
*** Testing gethostbynamel() : basic functionality ***
array(%d) {
%a
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
bool(false)
int(2130706433)
int(-1062731776)
bool(false)
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECT--
bool(false)
int(2130706433)
int(3232235520)
bool(false)
bool(false)
-===DONE===
var_dump( syslog($priority, $message) );
?>
-===DONE===
--EXPECT--
*** Testing syslog() : basic functionality ***
bool(true)
-===DONE===
);
var_dump(substr($hash, -1, 1) !== "\0");
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
<?php
var_dump(PHP_WINDOWS_VERSION_MAJOR > 0, PHP_WINDOWS_VERSION_MAJOR, PHP_WINDOWS_VERSION_MINOR);
?>
-==DONE==
--EXPECTF--
bool(true)
int(%d)
int(%d)
-==DONE==
var_dump($rf->getNumberOfParameters());
var_dump($rf->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(1)
int(2)
int(2)
-===DONE===
var_dump(unserialize('a:3:{i:0;s:3:"foo";i:1;s:3:"bar";i:2;s:3:"baz";}'));
var_dump(unserialize('O:8:"stdClass":0:{}'));
?>
-===DONE===
--EXPECTF--
bool(false)
bool(true)
}
object(stdClass)#%d (0) {
}
-===DONE===
echo "===AutoNA===\n";
var_dump(unserialize('O:22:"autoload_not_available":0:{}'));
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
===O1===
TestOld::__sleep()
["__PHP_Incomplete_Class_Name"]=>
string(22) "autoload_not_available"
}
-===DONE===
var_dump(unserialize("s:3:\"123;"));
var_dump(unserialize("s:0:\"123\";"));
?>
-===DONE===
--EXPECTF--
Notice: unserialize(): Error at offset 0 of 8 bytes in %sbug25378.php on line %d
bool(false)
Notice: unserialize(): Error at offset 5 of 10 bytes in %sbug25378.php on line %d
bool(false)
-===DONE===
var_dump(class_exists('autoload_implements', false));
?>
-===DONE===
--EXPECTF--
bool(false)
bool(false)
bool(true)
bool(true)
bool(true)
-===DONE===
var_dump($before, $after);
?>
-===DONE===
--EXPECTF--
object(TestY)#%d (2) {
["A"]=>
int(1)
}
}
-===DONE===
<?php
var_dump(unserialize('a:6:{a:6:{s:3:"322";s:3:"bar";s:3:"bar";s:3:"foo";a:6:{a:6:{s:3:"322";s:3:"bar";s:3:"bar";s:3:"foo";s:3:"bar";a:6:{a:6:{s:3:"322";s:3:"bar";s:3:"bar";s:3:"foo";a:6:{a:6:{s:3:"322";s:3:"bar";s:3:"b22";s:3:"bar";s:3:"bar";s:3:"foo";s:3:"bar";a:6:{a:6:{s:3:"322";s:3:"bar";s:3:"bar";s:3:"foo";s:3:"bar";s:3:"bar";'));
?>
-===DONE===
--EXPECTF--
Notice: unserialize(): Error at offset %d of %d bytes in %sbug68545.php on line %d
bool(false)
-===DONE===
var_dump($data);
?>
-===DONE===
--EXPECT--
array(2) {
[0]=>
[1]=>
int(1)
}
-===DONE===
var_dump(unserialize('d:2e+2;'));
var_dump(unserialize('d:2e++2;'));
?>
-===DONE===
--EXPECTF--
float(200)
Notice: unserialize(): Error at offset 0 of 8 bytes in %s on line %d
bool(false)
-===DONE===
?>
-==DONE==
--EXPECT--
stream_open: yes
url_stat: yes
rename: yes
unlink: yes
touch: yes
-==DONE==
var_dump(@opendir($dir));
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
-===DONE===
fclose($stream);
unlink($filename);
?>
-===DONE===
--EXPECTF--
Notice: stream_get_contents(): read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
string(0) ""
Notice: stream_get_contents(): read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
string(0) ""
-===DONE===
echo "no process\n";
}
?>
-==DONE==
--EXPECTF--
Warning: Array to string conversion in %s on line %d
int(%d)
int(0)
bool(true)
-==DONE==
echo "Can't start external command\n";
}
?>
-===DONE===
--EXPECT--
Test
External command executed
STDOUT: testtext
STDERR:
-===DONE===
echo "no process\n";
}
?>
-==DONE==
--EXPECTF--
int(%d)
int(0)
-==DONE==
proc_close($srv_proc);
unlink($srv_fl);
?>
-==DONE==
--EXPECT--
int(0)
-==DONE==
$ds=opendir($path, $context);
var_dump($ds);
?>
-==DONE==
--EXPECTF--
Warning: opendir(ftps://127.0.0.1:%d/): failed to open dir: Server doesn't support FTPS. in %s on line %d
bool(false)
-==DONE==
fclose($fp0);
unlink($fname);
?>
-==DONE==
--EXPECT--
bool(false)
NULL
-==DONE==
$ds=file_get_contents($path);
var_dump($ds);
?>
-==DONE==
--EXPECTF--
Warning: file_get_contents(ftp://127.0.0.1:%d/bug73457): failed to open stream: Failed to set up data channel: Connection refused in %s on line %d
bool(false)
-==DONE==
stream_socket_shutdown($fd, STREAM_SHUT_RDWR);
stream_socket_shutdown($server, STREAM_SHUT_RDWR);
?>
-==DONE==
--EXPECT--
bool(true)
-==DONE==
mkdir($path, 0755, true);
?>
-==DONE==
--EXPECTF--
string(20) "CWD /one/two/three
"
"
string(20) "MKD /one/two/three
"
-==DONE==
var_dump(stat($path)['mode']);
?>
-==DONE==
--EXPECTF--
string(11) "SIZE /www
"
int(16877)
-==DONE==
var_dump(opendir($path));
?>
-==DONE==
--EXPECTF--
Warning: opendir(ftp://localhost:%d/bogusdir): failed to open dir: FTP server reports 250 /bogusdir: No such file or directory
in %s on line %d
bool(false)
-==DONE==
closedir($ds);
?>
-==DONE==
--EXPECTF--
resource(%d) of type (stream)
string(5) "file1"
string(5) "file1"
string(3) "fil"
string(4) "b0rk"
-==DONE==
var_dump(opendir($path, $context));
?>
-==DONE==
--EXPECTF--
Warning: opendir(ftps://127.0.0.1:%d/bogusdir): failed to open dir: FTP server reports 250 /bogusdir: No such file or directory
in %s on line %d
bool(false)
-==DONE==
var_dump($fn);
}
?>
-==DONE==
--EXPECTF--
resource(%d) of type (stream)
string(5) "file1"
string(5) "file1"
string(3) "fil"
string(4) "b0rk"
-==DONE==
), strlen($stdout), strlen($stderr));
?>
-===DONE===
--CLEAN--
<?php
$callee = __DIR__ . "/process_proc_open_bug51800.php";
}
int(10000)
int(10000)
-===DONE===
), strlen($stdout), strlen($stderr));
?>
-===DONE===
--CLEAN--
<?php
$callee = __DIR__ . "/process_proc_open_bug51800_right.php";
}
int(10000)
int(10000)
-===DONE===
), strlen($stdout), strlen($stderr));
?>
-===DONE===
--CLEAN--
<?php
$callee = __DIR__ . "/process_proc_open_bug51800_right2.php";
}
int(1000000)
int(1000000)
-===DONE===
var_dump($pipeEvents);
?>
-===DONE===
--EXPECTF--
array(2) {
[%d]=>
string(12) "Closing pipe"
}
}
-===DONE===
proc_close($process);
?>
-===DONE===
--CLEAN--
<?php
$fl = __DIR__ . DIRECTORY_SEPARATOR . "test69900.php";
fgets() took less than %d ms
hello9
fgets() took less than %d ms
-===DONE===
var_dump(ob_get_contents());
?>
-===DONE===
--EXPECTF--
Warning: highlight_file(AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA): failed to open stream: %s006.php on line %d
Warning: highlight_file(): Failed opening 'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' for highlighting in %s006.php on line %d
bool(false)
bool(false)
-===DONE===
var_dump(ob_get_contents());
?>
-===DONE===
--EXPECTF--
Warning: php_strip_whitespace(%s): failed to open stream: No such file or directory in %s on line %d
string(0) ""
bool(false)
-===DONE===
var_dump(ob_get_contents());
?>
-===DONE===
--EXPECTF--
Warning: php_strip_whitespace(%s): failed to open stream: File name too long in %s007.php on line %d
string(0) ""
bool(false)
-===DONE===
$count ++;
}
?>
-===DONE===
--EXPECT--
*** Testing bin2hex() : basic functionality ***
-- Iteration 1 --
string(112) "5c74205468697320537472696e6720636f6e7461696e73205c745c7420736f6d6520636f6e74726f6c20636861726163746572735c725c6e"
-- Iteration 6 --
string(144) "5c7839305c7839315c7830305c7839335c7839345c7839305c7839315c7839355c7839365c7839375c7839385c7839395c7839615c7839625c7839635c7839645c7839655c783966"
-===DONE===
<?php
echo substr('cd', -3) . "\n";
?>
-===DONE===
--EXPECT--
cd
-===DONE===
echo quoted_printable_encode(str_repeat("\xc4\x85", 77));
?>
-==DONE==
--EXPECT--
=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=
=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=
=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=
=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=
=C4=85=C4=85=C4=85=C4=85=C4=85
-==DONE==
$a = pack("AAAAAAAAAAAA", 1,2,3,4,5,6,7,8,9,10,11,12);
$b = unpack('h2147483648', $a);
?>
-===DONE===
--EXPECTF--
Warning: unpack(): Type h: integer overflow in %s on line %d
-===DONE===
strtr(11, array('aaa' => 'bbb'))
);
?>
-===DONE===
--EXPECT--
string(2) "11"
-===DONE===
strip_tags('<foo<?>bar>')
);
?>
-===DONE===
--EXPECT--
string(0) ""
string(0) ""
string(0) ""
-===DONE===
echo "World";
echo "\n";
?>
-===DONE===
--EXPECT--
*** Testing chr() : basic functionality ***
Hello
World
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing chr() : error conditions ***
-- Testing chr() function with more than expected no. of arguments --
chr() expects exactly 1 parameter, 2 given
-===DONE===
fclose($file_handle); //closing the file handle
?>
-===DONE===
--EXPECT--
*** Testing chr() function: with unexpected inputs for 'ascii' argument ***
-- Iteration 1 --
string(2) "00"
-- Iteration 15 --
string(2) "00"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing convert_cyr_string() : basic functionality ***
253: dc
254: c0
255: d1
-===DONE===
var_dump(bin2hex( convert_cyr_string($str, ">", "?")) );
?>
-===DONE===
--EXPECTF--
*** Testing convert_cyr_string() : error conditions ***
Warning: convert_cyr_string(): Unknown destination charset: ? in %s on line %d
string(10) "68656c6c6f"
-===DONE===
echo "TEST PASSED\n";
?>
-===DONE===
--EXPECT--
*** Testing convert_uudecode() : basic functionality ***
TEST PASSED
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing convert_uuencode() : basic functionality ***
-- Iteration 1 --
+<F%C=&5R<UQR7&X`
`
"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing count_chars() : basic functionality ***
array(256) {
string(18) " Rabcdefghimnorstu"
string(476) "000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f2122232425262728292a2b2c2d2e2f303132333435363738393a3b3c3d3e3f404142434445464748494a4b4c4d4e4f5051535455565758595a5b5c5d5e5f606a6b6c7071767778797a7b7c7d7e7f808182838485868788898a8b8c8d8e8f909192939495969798999a9b9c9d9e9fa0a1a2a3a4a5a6a7a8a9aaabacadaeafb0b1b2b3b4b5b6b7b8b9babbbcbdbebfc0c1c2c3c4c5c6c7c8c9cacbcccdcecfd0d1d2d3d4d5d6d7d8d9dadbdcdddedfe0e1e2e3e4e5e6e7e8e9eaebecedeeeff0f1f2f3f4f5f6f7f8f9fafbfcfdfeff"
Unknown mode
-===DONE===
$pieces = explode(" p", $pizza);
var_dump($pieces);
?>
-===DONE===
--EXPECT--
*** Testing explode() function: match longer string ***
array(7) {
[6]=>
string(0) ""
}
-===DONE===
echo "\n-- negative limit (since PHP 5.1) with null string -- \n";
var_dump(explode('||', "", -1));
?>
-===DONE===
--EXPECT--
*** Testing explode() function: positive and negative limits ***
-- negative limit (since PHP 5.1) with null string --
array(0) {
}
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
*** Testing explode() function: misc tests ***
string(6) "74776f"
string(10) "7468726565"
string(8) "666f7572"
-===DONE===
var_dump(hebrev($hebrew_text, 15));
?>
-===DONE===
--EXPECT--
*** Testing hebrev() : basic functionality ***
string(109) ".The hebrev function converts logical Hebrew text to visual text
tries to avoid
.The function
"
-===DONE===
var_dump(hebrevc($hebrew_text, 15));
?>
-===DONE===
--EXPECTF--
*** Testing hebrevc() : basic functionality ***
tries to avoid<br />
.The function<br />
"
-===DONE===
print mb_internal_encoding()."\n";
var_dump(bin2hex(htmlentities("\x81\x41\x81\x42\x81\x43", ENT_QUOTES, '')));
?>
-===DONE===
--EXPECTF--
SJIS
Notice: htmlentities(): Only basic entities substitution is supported for multi-byte encodings other than UTF-8; functionality is equivalent to htmlspecialchars in %s line %d
string(12) "814181428143"
-===DONE===
var_dump(bin2hex($str), bin2hex(htmlentities($str, ENT_QUOTES, '')));
var_dump(htmlentities($str, ENT_QUOTES | ENT_HTML5, ''));
?>
-===DONE===
--EXPECT--
string(22) "88a9f0eef1eaeef8edfbe9"
string(42) "266575726f3b26636f70793bf0eef1eaeef8edfbe9"
string(58) "€©роскошный"
-===DONE===
echo "Test 29: " . htmlspecialchars ($s2, ENT_NOQUOTES, "ISO-8859-1", true);
?>
-===DONE===
--EXPECT--
*** Testing htmlspecialchars() : basic functionality ***
Basic tests
Try with double decode TRUE
Test 28: &quot;&amp;xyz&gt;abc&quot;
Test 29: &quot;&amp;123&lt;456&quot;
-===DONE===
var_dump(ltrim($binary, "\x00..\x1F"));
?>
-===DONE===
--EXPECT--
*** Testing ltrim() : basic functionality ***
-- Trim the ASCII control characters at the beginning of a string --
string(14) "Example string"
-===DONE===
var_dump(ltrim($hello, "a..b..c"));
?>
-===DONE===
--EXPECTF--
*** Testing ltrim() : error conditions ***
Warning: ltrim(): Invalid '..'-range in %s on line %d
string(14) " Hello World
"
-===DONE===
echo "*** Testing md5() : basic functionality ***\n";
var_dump(md5("apple"));
?>
-===DONE===
--EXPECT--
*** Testing md5() : basic functionality ***
string(32) "1f3870be274f6c49b3e31a0c6728957f"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing md5() : basic functionality - with raw output***
string(32) "b10a8db164e0754105b7a99be72e3fe5"
TEST PASSED
-===DONE===
echo gettype(money_format('%=*!14#8.2n', $negative_value))."\n";
?>
-===DONE===
--EXPECTF--
*** Testing money_format() : basic functionality***
Format values with 14 positions, 8 digits to left, 2 to right using national format
Deprecated: Function money_format() is deprecated in %s on line %d
string
-===DONE===
echo "\n-- Testing money_format() function with more than one token --\n";
var_dump( money_format($string . $string, $value) );
?>
-===DONE===
--EXPECTF--
*** Testing money_format() : error conditions ***
Warning: money_format(): Only a single %ci or %cn token can be used in %s on line %d
bool(false)
-===DONE===
setlocale(LC_ALL, $original);
?>
-===DONE===
--EXPECT--
*** Testing nl_langinfo() : basic functionality ***
string(3) "Mon"
string(3) "Jul"
string(5) "April"
string(1) "."
-===DONE===
var_dump($res);
}
?>
-===DONE===
--EXPECT--
*** Testing number_format() : basic functionality ***
string(4) "0,00"
string(4) "1,00"
string(4) "0,00"
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing ord() : basic functionality ***
int(97)
int(10)
int(255)
int(72)
-===DONE===
var_dump($res3_array);
?>
-===DONE===
--EXPECTF--
*** Testing parse_str() : basic functionality ***
["third"]=>
string(4) "val3"
}
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing parse_str() : non-default arg_separator.input specified ***
NULL
["third"]=>
string(4) "val3"
}
-===DONE===
var_dump(parse_str($str, $res));
var_dump($res);
?>
-===DONE===
--EXPECTF--
Test string with badly formed strings
NULL
}
}
}
-===DONE===
line with just a semicolon no extra whitespace!\n
END;
?>
-===DONE===
--EXPECT--
*** Testing print() : basic functionality ***
multiple lines with VARIABLE interpolation. Note
that the here document terminator must appear on a
line with just a semicolon no extra whitespace!
-===DONE===
fclose($file_handle); //closing the file handle
?>
-===DONE===
--EXPECTF--
*** Testing print() function: with unexpected inputs for 'arg' argument ***
-- Iteration 1 --
-- Iteration 21 --
int(1)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using string format ***
-- Calling printf() with string three arguments --
arg1 argument arg2 argument arg3 argument
int(41)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using integer format ***
-- Calling printf() with three arguments--
111 222 333
int(11)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using float format ***
int(29)
11.110000 22.220000 33.330000
int(29)
-===DONE===
echo "\n";
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using bool format ***
-- Calling printf() with three arguments--
1 0 1
int(5)
-===DONE===
echo "\n";
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using char format ***
-- Calling printf() with three arguments --
A B C
int(5)
-===DONE===
echo "\n";
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using exponential format ***
-- Calling printf() with three arguments --
1.000000e+3 2.000000E+3 3.000000e+3
int(35)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using unsigned format ***
-- Calling printf() with three arguments --
4294966185 4293732729 2345432
int(29)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using octal format ***
-- Calling printf() with three arguments --
21 37777777431 567
int(18)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing printf() : basic functionality - using hexadecimal format ***
int(7)
B 84 B1
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing printf() : error conditions ***
-- Call printf with three argument less than expected --
4 parameters are required, 1 given
-===DONE===
fclose($file_handle);
?>
-===DONE===
--EXPECTF--
*** Testing printf() : with unexpected values for format argument ***
int(%d)
Resource id #%d
int(%d)
-===DONE===
fclose($file_handle);
?>
-===DONE===
--EXPECTF--
*** Testing printf() : with different types of values passed for arg1 argument ***
int(%d)
Resource id #%d
int(%d)
-===DONE===
var_dump(bin2hex(quoted_printable_decode($str)));
?>
-===DONE===
--EXPECT--
*** Testing quoted_printable_decode() : basic functionality ***
string(76) "fa776f772d666163746f72c1d0d5ddc5ceced9c50a20d4cfd2c7cfd7d9c520d0d2cfc5cbd4d9"
-===DONE===
var_dump(quotemeta("(100 + 50) * 10"));
var_dump(quotemeta("\+*?[^]($)"));
?>
-===DONE===
--EXPECT--
*** Testing quotemeta() : basic functionality ***
string(20) "Hello how are you \?"
string(19) "\(100 \+ 50\) \* 10"
string(20) "\\\+\*\?\[\^\]\(\$\)"
-===DONE===
var_dump(rtrim($binary, "\x00..\x1F"));
?>
-===DONE===
--EXPECT--
*** Testing rtrim() : basic functionality ***
-- Trim the ASCII control characters at the beginning of a string --
string(14) "Example string"
-===DONE===
var_dump(rtrim($hello, "a..b..c"));
?>
-===DONE===
--EXPECTF--
*** Testing rtrim() : error conditions ***
Warning: rtrim(): Invalid '..'-range in %s on line %d
string(14) " Hello World
"
-===DONE===
var_dump(setlocale(LC_ALL, 'us_UK'));
var_dump(setlocale(LC_ALL, 'us_US'));
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
string(26) "English_United States.1252"
string(27) "English_United Kingdom.1252"
string(26) "English_United States.1252"
-===DONE===
var_dump(bin2hex(sha1("12345678901234567890123456789012345678901234567890123456789012345678901234567890", true)));
?>
-===DONE===
--EXPECT--
*** Testing sha1() : basic functionality ***
string(40) "32d10c7b8cf96570ca04ce37f2a19d84240d3a89"
string(40) "761c457bf73b14d27e9e9265c46f4b4dda11f940"
string(40) "50abf5706a150990a08b2c5ea40fa0e585554732"
-===DONE===
unlink("EmptyFileSHA1.txt");
?>
-===DONE===
--EXPECTF--
*** Testing sha1_file() : basic functionality ***
-- Raw Binary Output for a valid file with some contents --
string(40) "d16a568ab98233deff7ec8b1668eb4b3d9e53fee"
-===DONE===
similar_text("abcdefghabcdef", "zzzzabcdefggg", $percent);
var_dump($percent);
?>
-===DONE===
--EXPECT--
int(3)
int(0)
float(0)
float(18.181818181818)
float(51.851851851852)
-===DONE===
var_dump(soundex("Lukasiewicz") == soundex("Ghosh"));
var_dump(soundex("Hilbert") == soundex("Ladd"));
?>
-===DONE===
--EXPECT--
*** Testing soundex() : basic functionality ***
string(4) "E460"
bool(true)
bool(false)
bool(false)
-===DONE===
closedir($dfp);
?>
-===DONE===
--EXPECTF--
*** Testing sprintf() : char formats with resource values ***
string(1) "%a"
string(11) "a-bA-B@#$&]"
string(1) "c"
-===DONE===
closedir($dfp);
?>
-===DONE===
--EXPECTF--
*** Testing sprintf() : hexa formats with resource values ***
string(30) "%a"
string(10) "0-9A-Fa-f]"
string(1) "x"
-===DONE===
closedir($dfp);
?>
-===DONE===
--EXPECTF--
*** Testing sprintf() : scientific formats with resource values ***
string(30) "%s%f"
string(%d) "0-1]"
string(1) "e"
-===DONE===
var_dump($res, $part, $number, $stock);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality - using string format ***
string(6) "Widget"
string(7) "1234789"
string(2) "25"
-===DONE===
var_dump($res, $part, $number, $stock);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality - using integer format ***
string(6) "Widget"
int(1234789)
int(25)
-===DONE===
var_dump($res, $part, $length, $width, $depth);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality -- using float format ***
float(111.53)
float(22.345)
float(12.4)
-===DONE===
var_dump($res, $arg1, $arg2, $arg3, $arg4);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality - using char format ***
string(1) "A"
string(1) "B"
string(1) "C"
-===DONE===
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality -using exponential format ***
float(10123.45)
float(10123.45)
float(-101234.5)
-===DONE===
var_dump($res, $arg1, $arg2, $arg3, $arg4, $arg5, $arg6);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality - using unsigned format ***
string(10) "4294967285"
NULL
NULL
-===DONE===
var_dump($res, $arg1, $arg2, $arg3, $arg4, $arg5, $arg6);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality - using octal format ***
int(10)
NULL
NULL
-===DONE===
var_dump($res, $arg1, $arg2, $arg3, $arg4, $arg5, $arg6);
?>
-===DONE===
--EXPECT--
*** Testing sscanf() : basic functionality - - using hexadecimal format ***
int(-4667)
int(6844)
int(1)
-===DONE===
var_dump( sscanf($str, $format, $str1, $str2, $extra_str) );
?>
-===DONE===
--EXPECTF--
*** Testing sscanf() : error conditions ***
Warning: sscanf(): Variable is not assigned by any conversion specifiers in %s on line %d
int(-1)
-===DONE===
EOS;
print_r(str_getcsv($contents, ',', '"', ''));
?>
-===DONE===
--EXPECT--
Array
(
[2] => cell3
[3] => cell4
)
-===DONE===
fclose($fp);
?>
-===DONE===
--EXPECTF--
*** Testing str_replace() on basic operations ***
string(0) ""
int(0)
string(%d) "Resource id #%d"
int(1)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing str_replace() with various search values ***
-- Iteration 0 --
string(0) ""
}
int(0)
-===DONE===
closedir($resource2);
?>
-===DONE===
--EXPECTF--
*** Testing Miscelleneous input data ***
string(3) "qqq"
string(0) ""
string(5) "FOUND"
string(5) "FOUND"
-===DONE===
echo "Strings unequal : TEST FAILED\n";
}
?>
-===DONE===
--EXPECT--
*** Testing str_rot13() : basic functionality ***
Ensure strings round trip
Strings equal : TEST PASSED
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing str_shuffle() : basic functionality ***
string(47) "%s"
TEST PASSED
-===DONE===
zend_terminate_string($a);
zend_terminate_string($b);
?>
-===DONE===
--EXPECT--
int(-1)
int(1)
-===DONE===
var_dump(bin2hex(stripcslashes('\\t')));
var_dump(bin2hex(stripcslashes('\\v')));
?>
-===DONE===
--EXPECT--
*** Testing stripcslashes() : basic functionality ***
string(11) "Hello World"
string(2) "0c"
string(2) "09"
string(2) "0b"
-===DONE===
var_dump( stristr("Test String", "String", false) );
var_dump( stristr("Test String", "String", true) );
?>
-===DONE===
--EXPECT--
*** Testing stristr() : basic functionality ***
string(11) "Test string"
string(4) "teSt"
string(6) "String"
string(5) "Test "
-===DONE===
fclose($file_handle); //closing the file handle
?>
-===DONE===
--EXPECT--
*** Testing stristr() function: with unexpected inputs for 'needle' argument ***
-- Iteration 1 --
string(11) "Hello World"
-- Iteration 20 --
string(11) "Hello World"
-===DONE===
var_dump(strlen(""));
var_dump(strlen("\x90\x91\x00\x93\x94\x90\x91\x95\x96\x97\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"));
?>
-===DONE===
--EXPECT--
*** Testing strlen() : basic functionality ***
int(6)
int(7)
int(0)
int(18)
-===DONE===
str_dump(0xFFF, 0Xfff);
?>
-===DONE===
--EXPECT--
*** Testing strnatcasecmp() : basic functionality ***
int(0)
int(0)
int(-1)
int(0)
-===DONE===
str_dump($a, $b);
?>
-===DONE===
--EXPECT--
*** Testing strnatcasecmp() : variation ***
int(1)
int(-1)
int(0)
int(0)
-===DONE===
var_dump(strnatcmp($c1, $b2));
var_dump(strnatcmp($c1, $d2));
?>
-===DONE===
--EXPECT--
*** Testing strnatcmp() : basic functionality ***
Less than tests
int(1)
int(1)
int(1)
-===DONE===
var_dump( strpbrk(5, "5") );
?>
-===DONE===
--EXPECT--
*** Testing strpbrk() : basic functionality ***
string(20) "is is a Simple text."
string(12) " aaa aaaSLR"
string(1) "5"
string(1) "5"
-===DONE===
var_dump( strpbrk($haystack, '') );
?>
-===DONE===
--EXPECTF--
*** Testing strpbrk() : error conditions ***
Warning: strpbrk(): The character list cannot be empty in %s on line %d
bool(false)
-===DONE===
var_dump( strripos($heredoc_str, $heredoc_str) );
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: basic functionality ***
int(0)
int(0)
int(0)
-===DONE===
var_dump( strripos("Hello, World", "O", -5) );
var_dump( strripos("Hello, World", "O", -9) );
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: basic functionality ***
int(8)
int(4)
bool(false)
-===DONE===
$count++;
}
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: with double quoted strings ***
-- Iteration 1 --
bool(false)
bool(false)
int(0)
-===DONE===
$count++;
}
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: with single quoted strings ***
-- Iteration 1 --
bool(false)
bool(false)
int(0)
-===DONE===
var_dump( strripos($multi_line_str, " ") );
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: with heredoc strings ***
-- With heredoc string containing multi lines --
int(31)
int(63)
int(55)
-===DONE===
var_dump( strripos($special_chars_str, "(speCIal)") );
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: with heredoc strings ***
-- With heredoc string containing special chars --
int(55)
int(55)
int(57)
-===DONE===
var_dump( strripos($control_char_str, "\t", 15) );
?>
-===DONE===
--EXPECT--
*** Testing strripos() function: with heredoc strings ***
-- With heredoc string containing escape characters --
int(19)
int(13)
int(19)
-===DONE===
fclose($file_handle); //closing the file handle
?>
-===DONE===
--EXPECTF--
*** Testing strtr() function: with unexpected inputs for 'from' ***
-- Iteration 1 --
string(6) "012atm"
-- Iteration 19 --
string(6) "012atm"
-===DONE===
$iterator++;
};
?>
-===DONE===
--EXPECT--
*** Testing strval() : basic variations ***
-- Iteration 7 --
string(21) "Simple HEREDOC string"
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing strval() : error conditions ***
-- Testing strval() function with object which has not toString() method --
Object of class MyClass could not be converted to string
-===DONE===
$iterator++;
};
?>
-===DONE===
--EXPECTF--
*** Testing strval() : usage variations ***
-- Iteration 31 --
string(0) ""
-===DONE===
echo "\n";
?>
-===DONE===
--EXPECT--
*** Testing strval() : usage variations - Pass all valid char codes ***
000102030405060708090a0b0c0d0e0f
d0d1d2d3d4d5d6d7d8d9dadbdcdddedf
e0e1e2e3e4e5e6e7e8e9eaebecedeeef
f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff
-===DONE===
var_dump(substr_replace($s1, "evening", array(5), array(8)));
?>
-===DONE===
--EXPECTF--
*** Testing substr_replace() : error conditions ***
Warning: substr_replace(): Functionality of 'start' and 'length' as arrays is not implemented in %s on line %d
string(12) "Good morning"
-===DONE===
var_dump(trim($binary, "\x00..\x1F"));
?>
-===DONE===
--EXPECT--
*** Testing trim() : basic functionality ***
-- Trim the ASCII control characters at the beginning of a string --
string(14) "Example string"
-===DONE===
var_dump(trim($hello, "a..b..c"));
?>
-===DONE===
--EXPECTF--
*** Testing trim() : error conditions ***
Warning: trim(): Invalid '..'-range in %s on line %d
string(14) " Hello World
"
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
array(1) {
["a"]=>
["d"]=>
int(2)
}
-===DONE===
$extra_arg = 10;
var_dump(unpack("B", pack("I", 65534)));
?>
-===DONE===
--EXPECTF--
*** Testing unpack() : error conditions ***
Warning: unpack(): Invalid format type B in %s on line %d
bool(false)
-===DONE===
fclose( $fp );
?>
-===DONE===
--CLEAN--
<?php
int(2)
string(35) "Testing 1001 6 2.550200 foobar f 41"
int(35)
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using string format ***
int(4)
one
one two
one two three
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using integer format ***
111
111 222
111 222 333
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using float format ***
11.110000
11.110000 22.220000
11.110000 22.220000 33.330000
11.110000 22.220000 33.330000
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using bool format ***
1
1 0
1 0 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using char format ***
A
A B
A B C
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using exponential format ***
1.000000e+3
1.000000e+3 2.000000e+3
1.000000e+3 2.000000e+3 3.000000e+3
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using unsigned format ***
4294966185
4294966185 4293732729
4294966185 4293732729 4292621864
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using unsigned format ***
18446744073709550505
18446744073709550505 18446744073708317049
18446744073709550505 18446744073708317049 18446744073707206184
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : basic functionality - using octal format ***
21
21 347
21 347 567
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf) : basic functionality - using hexadecimal format ***
b
B 84
b 84 b1
B 84 B1
-===DONE===
fclose($fp);
?>
-===DONE===
--CLEAN--
<?php
-- Testing vfprintf() function with more than expected no. of arguments --
Wrong parameter count for vfprintf()
Wrong parameter count for vfprintf()
-===DONE===
fclose( $fp );
?>
-===DONE===
--CLEAN--
<?php
string(5) "Array"
int(9)
string(9) "Foo fake"
-===DONE===
fclose( $fp );
?>
-===DONE===
--CLEAN--
<?php
-- Testing vfprintf() function with other strangeties --
vfprintf() expects parameter 1 to be resource, string given
Error found: Argument number must be greater than zero.
-===DONE===
fclose( $fp );
?>
-===DONE===
--CLEAN--
<?php
int(0)
string(38) "Testing 1001 6 2.550200 30 foobar f 41"
int(38)
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : octal formats with octal values ***
% %o o
-- Iteration 8 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : octal formats with octal values ***
% %o o
-- Iteration 8 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : octal formats and non-octal values ***
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : octal formats and non-octal values ***
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : hexa formats with hexa values ***
%34 x
-- Iteration 8 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : hexa formats with hexa values ***
%34 x
-- Iteration 8 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : hexa formats and non-hexa values ***
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : hexa formats and non-hexa values ***
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : unsigned formats and unsigned values ***
#1 0 $0 10
-- Iteration 5 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : unsigned formats and unsigned values ***
#1 0 $0 10
-- Iteration 5 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : unsigned formats and signed & other types of values ***
1 1 0
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : unsigned formats and signed & other types of values ***
1 1 0
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : scientific formats and scientific values ***
#########1.000000e+1 1.000000e+2 $$$$$$$$-1.000000e+3 _________1.000000e+2
-- Iteration 5 --
1.000000e+3 2.000000e+3 3.000000e+3 4.000000e+3
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : scientific formats and non-scientific values ***
1.0000e+0 0.0000e+0 1.000000e+0 0.0000e+0
0.000000e+0 1.000000e+0 1.000000e+0 0.000000e+0
0.000000e+0 1.000000e+0 1.000000e+0 1.000000e+0
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : with white spaces in format strings ***
11 FFFFFFDE 33
-- Iteration 11 --
2.000000E+1 2.000000E-1 -2.000000E+1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : with white spaces in format strings ***
11 FFFFFFFFFFFFFFDE 33
-- Iteration 11 --
2.000000E+1 2.000000E-1 -2.000000E+1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECTF--
*** Testing vfprintf() : with unexpected values for format argument ***
-- Iteration 26 --
Resource id #%d
-===DONE===
?>
-===DONE===
--EXPECTF--
*** Testing vfprintf() : with unexpected values for args argument ***
-- Iteration 23 --
Resource id #%d
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : int formats with int values ***
%-5678 d
-- Iteration 8 --
1 2 3 4
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : int formats and non-integer values ***
1 0 1 0000
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : int formats and non-integer values ***
1 0 1 0000
#0 1 $1 _0
0 1 1 1
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : int formats with float values ***
%-5678.567800 f
-- Iteration 8 --
1.110000 2.220000 3.330000 4.440000
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECT--
*** Testing vfprintf() : float formats and non-float values ***
1.0000 0.0000 1.000000 0.0000
0.000000 1.000000 1.000000 0.000000
0.000000 1.000000 1.000000 1.000000
-===DONE===
unlink($data_file);
?>
-===DONE===
--EXPECTF--
*** Testing vfprintf() : string formats and non-string values ***
1 0001 0000
#0 1 $1 _0
1 1 1
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using string format ***
one
int(7)
one two three
int(13)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using integer format ***
111
int(7)
111 222 333
int(11)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using float format ***
11.110000
int(29)
11.110000 22.220000 33.330000
int(29)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using bool format ***
1
int(3)
1 0 1
int(5)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using char format ***
A
int(3)
A B C
int(5)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using exponential format ***
1.000000e+3
int(23)
1.000000e+3 2.000000e+3 3.000000e+3
int(35)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using unsigned format ***
4294966185
int(21)
4294966185 4293732729 4292621864
int(32)
-===DONE===
echo "\n";
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using unsigned format ***
18446744073709550505
int(41)
18446744073709550505 18446744073708317049 18446744073707206184
int(62)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using octal format ***
21
int(6)
21 347 567
int(10)
-===DONE===
var_dump($result);
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : basic functionality - using hexadecimal format ***
b
int(7)
B 84 B1
int(7)
-===DONE===
fclose($file_handle);
?>
-===DONE===
--EXPECTF--
*** Testing vprintf() : with unexpected values for format argument ***
-- Iteration 26 --
Resource id #%d
int(%d)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : octal formats with octal values ***
-- Iteration 8 --
1 2 3 4
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : octal formats with octal values ***
-- Iteration 8 --
1 2 3 4
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : octal formats and non-octal values ***
#0 1 $1 _0
0 1 1 1
int(75)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : octal formats and non-octal values ***
#0 1 $1 _0
0 1 1 1
int(75)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : hexa formats with hexa values ***
-- Iteration 8 --
1 2 3 4
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : hexa formats with hexa values ***
-- Iteration 8 --
1 2 3 4
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : hexa formats and non-hexa values ***
#0 1 $1 _0
0 1 1 1
int(75)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : hexa formats and non-hexa values ***
#0 1 $1 _0
0 1 1 1
int(75)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : unsigned formats and unsigned values ***
-- Iteration 5 --
1 2 3 4
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : unsigned formats and unsigned values ***
-- Iteration 5 --
1 2 3 4
int(7)
-===DONE===
$counter++;
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : unsigned formats and signed & other types of values ***
#0 1 $1 _0
0 1 1 1
int(76)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : unsigned formats and signed & other types of values ***
#0 1 $1 _0
0 1 1 1
int(76)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : scientific formats and scientific values ***
-- Iteration 5 --
1.000000e+3 2.000000e+3 3.000000e+3 4.000000e+3
int(47)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : scientific formats and non-scientific values ***
0.000000e+0 1.000000e+0 1.000000e+0 0.000000e+0
0.000000e+0 1.000000e+0 1.000000e+0 1.000000e+0
int(227)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : with white spaces in format strings ***
-- Iteration 11 --
2.000000E+1 2.000000E-1 -2.000000E+1
int(38)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : with white spaces in format strings ***
-- Iteration 11 --
2.000000E+1 2.000000E-1 -2.000000E+1
int(38)
-===DONE===
fclose($file_handle);
?>
-===DONE===
--EXPECTF--
*** Testing vprintf() : with unexpected values for args argument ***
-- Iteration 23 --
Resource id #%d
int(%d)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : int formats with int values ***
-- Iteration 8 --
1 2 3 4
int(7)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : int formats and non-integer values ***
#0 1 $1 _0
0 1 1 1
int(81)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : int formats and non-integer values ***
#0 1 $1 _0
0 1 1 1
int(81)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : int formats with float values ***
-- Iteration 8 --
1.110000 2.220000 3.330000 4.440000
int(35)
-===DONE===
}
?>
-===DONE===
--EXPECT--
*** Testing vprintf() : float formats and non-float values ***
0.000000 1.000000 1.000000 0.000000
0.000000 1.000000 1.000000 1.000000
int(179)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing vprintf() : string formats and non-string values ***
#0 1 $1 _0
1 1 1
int(81)
-===DONE===
}
?>
-===Done===
--EXPECT--
*** Testing vsprintf() : unsigned formats and unsigned values ***
-- Iteration 5 --
string(7) "1 2 3 4"
-===Done===
}
?>
-===DONE===
--EXPECTF--
*** Testing vsprintf() : string formats and non-string values ***
1 0001 0000
#0 1 $1 _0
1 1 1"
-===DONE===
<?php
var_dump(strptime('2006-08-20', '%Y-%m-%d'));
?>
-===DONE===
--EXPECTF--
array(9) {
["tm_sec"]=>
["unparsed"]=>
string(0) ""
}
-===DONE===
setlocale(LC_ALL, $orig);
?>
-===DONE===
--EXPECT--
*** Testing strptime() : basic functionality ***
array(9) {
["unparsed"]=>
string(0) ""
}
-===DONE===
var_dump( strptime('foo', $format) );
?>
-===DONE===
--EXPECTF--
*** Testing strptime() : error conditions ***
-- Testing strptime() function on failure --
bool(false)
-===DONE===
setlocale(LC_ALL, $orig);
?>
-===DONE===
--EXPECT--
*** Testing strptime() : basic functionality ***
int(20)
int(2)
int(6)
int(0)
-===DONE===
}
?>
-===Done===
--EXPECT--
*** Testing base64_encode() : basic functionality ***
TEST PASSED
-- Iteration 5 --
TEST PASSED
-===Done===
shm_attach($v1,$v2);
?>
-==DONE==
--EXPECTF--
Warning: shm_attach(): failed for key 0x64: Not enough space in %s on line %d
-==DONE==
xml_parser_free($parser);
var_dump($vals);
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(4) "aent"
}
}
-===DONE===
xml_parse($parser, $xml);
var_dump(xml_get_error_code($parser) === XML_ERROR_EXTERNAL_ENTITY_HANDLING);
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
xml_set_element_handler($var1, new Exception(""), 4096);
xml_parse($var1, str_repeat("<a>", 10));
?>
-===DONE===
--EXPECTF--
Warning: Invalid callback Exception in %s%ebug72085.php:%d
Stack trace:
#0 {main}, no array or string given in %s%ebug72085.php on line %d
Warning: xml_parse(): Unable to call handler in %s%ebug72085.php on line %d
-===DONE===
parse(3015809298423721);
parse(20);
?>
-===DONE===
--EXPECTF--
Notice: xml_parser_set_option(): tagstart ignored, because it is out of range in %s%ebug72714.php on line %d
string(9) "NS1:TOTAL"
string(0) ""
-===DONE===
$reader = new XMLReader();
$reader->XML($xmlstring);
?>
-===DONE===
--EXPECTF--
books
books
Warning: XMLReader::XML(): Empty string supplied as input in %s on line %d
-===DONE===
unlink($filename);
?>
-===DONE===
--EXPECTF--
Warning: XMLReader::open(): Empty string supplied as input in %s on line %d
books
books
-===DONE===
// clean up
$reader->close();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__.'/003-get-errors.xml');
num: 1
NULL
num: 1
-===DONE===
$reader->close();
unlink($filename);
?>
-===DONE===
--EXPECT--
num: 1
idx: 2
idx: 2
num: 1
idx: 2
-===DONE===
// clean up
$reader->close();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__.'/003-move-errors.xml');
num: 1
bool(false)
book
-===DONE===
$reader->close();
unlink($filename);
?>
-===DONE===
--EXPECTF--
num: 1
idx: 2
Warning: XMLReader::moveToAttribute(): Attribute Name is required in %s on line %d
bool(false)
-===DONE===
$reader->close();
unlink($filename);
?>
-===DONE===
--EXPECT--
books
book
Attribute Name: idx
Attribute Value: 2
#text
-===DONE===
while ($reader->read());
$reader->close();
?>
-===DONE===
--EXPECT--
ok
-===DONE===
$reader->close();
?>
-===DONE===
--EXPECT--
ok
-===DONE===
}
$reader->close();
?>
-===DONE===
--EXPECTF--
file relaxNG: ok
string relaxNG: ok
Warning: XMLReader::setRelaxNGSchema(): Schema data source is required in %s on line %d
-===DONE===
echo "string DTD: ok\n";
}
?>
-===DONE===
--EXPECT--
file DTD: ok
string DTD: ok
-===DONE===
echo $reader->getAttribute('num');
echo "\n";
?>
-===DONE===
--EXPECT--
book 2
-===DONE===
echo $reader->getAttributeNs('isbn', 'uri');
echo "\n";
?>
-===DONE===
--EXPECT--
prefix:books 12isbn
-===DONE===
echo "\n";
$reader->close();
?>
-===DONE===
--EXPECT--
<book>test</book>
<books><book>test</book></books>
-===DONE===
$reader->close();
?>
-===DONE===
--EXPECT--
string(0) ""
NULL
NULL
string(0) ""
string(0) ""
-===DONE===
$reader->close();
?>
-===DONE===
--EXPECTF--
string(3) "123"
string(3) "456"
===FAIL===
Warning: XMLReader::read(): Element 'foo': %s
-===DONE===
// clean up
$reader->close();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__.'/_014.xml');
Warning: main(): Cannot write to read-only property in %s on line %d
Warning: main(): Cannot write to read-only property in %s on line %d
-===DONE===
// clean up
$reader->close();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__.'/015-get-errors.xml');
Warning: XMLReader::getAttributeNs(): Attribute Name and Namespace URI cannot be empty in %s on line %d
bool(false)
ns1:num: 1
-===DONE===
// clean up
$reader->close();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__.'/015-move-errors.xml');
?>
--EXPECTF--
Warning: XMLReader::moveToAttributeNs(): Attribute Name and Namespace URI cannot be empty in %s on line %d
-===DONE===
// clean up
$reader->close();
?>
-===DONE===
--CLEAN--
<?php
unlink(__DIR__.'/015.xml');
ns2:isbn: 4
Attribute does not exist
ns2:isbn: 4
-===DONE===
return;
}
?>
-===DONE===
--EXPECTF--
%sXMLReaderGood_bug71805.xml : Good!
%sXMLReaderBad_bug71805.xml : Good!
-===DONE===
$xml->setSchema($xsdfile);
while($xml->read());
?>
-===DONE===
--EXPECT--
bool(true)
-===DONE===
var_dump($rm->getNumberOfParameters());
var_dump($rm->getNumberOfRequiredParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(0)
-===DONE===
}
$reader->close();
?>
-===DONE===
--EXPECT--
base book
-===DONE===
unset($xw);
unlink($doc_dest);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1/>
-===DONE===
// Force to write and empty the buffer
echo xmlwriter_flush($xw, true);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1/>
-===DONE===
// Force to write and empty the buffer
echo xmlwriter_flush($xw, true);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1 attr1="attr1_value" att2="att2_value">Test text for tag1<tag2/></tag1>
-===DONE===
echo "ok.\n";
}
?>
-===DONE===
--EXPECT--
ok.
-===DONE===
unset($xw);
unlink($doc_dest);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1><!--comment--><!--comment #2--></tag1>
-===DONE===
unset($xw);
unlink($doc_dest);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1><!--comment--><!--comment #2--></tag1>
-===DONE===
unset($xw);
unlink($doc_dest);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8" standalone="standalonearg"?>
<tag1/>
-===DONE===
// Force to write and empty the buffer
echo $xw->flush(true);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8" standalone="standalone"?>
<tag1/>
-===DONE===
// Force to write and empty the buffer
echo $xw->flush(true);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1 attr1="attr1_value" attr2="attr2_value">Test text for tag1<tag2/></tag1>
-===DONE===
echo "ok.\n";
}
?>
-===DONE===
--EXPECT--
ok.
-===DONE===
unset($xw);
unlink($doc_dest);
?>
-===DONE===
--EXPECT--
<?xml version="1.0" encoding="UTF-8"?>
<tag1><!--comment--><!--comment #2--></tag1>
-===DONE===
}
}
?>
-===DONE===
--EXPECTF--
Exception: Test exception. in %s:%d
Stack trace:
#0 [internal function]: testFunction(Array)
#1 %s(%d): XSLTProcessor->transformToDoc(Object(DOMDocument))
#2 {main}
-===DONE===
var_dump(file_exists($filename));
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
-===DONE===
--CLEAN--
<?php
$filename = __DIR__ . DIRECTORY_SEPARATOR . 'bug70752.txt';
$zip->close();
?>
-===DONE===
--EXPECTF--
Warning: ZipArchive::setArchiveComment(): Comment must not exceed 65535 bytes in %s on line %d
bool(false)
Warning: ZipArchive::setCommentIndex(): Comment must not exceed 65535 bytes in %s on line %d
bool(false)
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__ . '/__tmp_oo_set_comment_error.zip');
var_dump($r->getNumberOfRequiredParameters());
var_dump($r->getNumberOfParameters());
?>
-===DONE===
--EXPECT--
int(1)
int(2)
int(2)
int(3)
-===DONE===
var_dump(deflate_add($resource, "aaaaaaaaaaaaaaaaaaaaaa", ZLIB_BLOCK));
?>
-===DONE===
--EXPECTF--
Warning: deflate_add(): zlib >= 1.2.4 required for BLOCK deflate; current version: %s in %s on line %d
bool(false)
-===DONE===
echo bin2hex(substr($deflated, strlen($deflated) - 4)) . "\n";
?>
-===DONE===
--EXPECT--
0000ffff
0000ffff
0000ffff
-===DONE===
?>
-===DONE===
--EXPECT--
bool(true)
gzread(): supplied resource is not a valid stream resource
bool(true)
gzread(): supplied resource is not a valid stream resource
-===DONE===
var_dump( bin2hex(gzcompress($smallstring) ));
?>
-===Done===
--EXPECT--
*** Testing gzcompress() : basic functionality ***
-- Compression level -1 --
-- Testing with no specified compression level --
string(70) "789c735428ce4dccc951282e29cacc4b5728c95748cecf2d284a2d2ee6020087a509cb"
-===Done===
var_dump(gzcompress($data, $level, $encoding));
?>
-===Done===
--EXPECTF--
*** Testing gzcompress() : error conditions ***
Warning: gzcompress(): encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE in %s on line %d
bool(false)
-===Done===
var_dump(md5(gzcompress($output)));
?>
-===Done===
--EXPECT--
*** Testing gzcompress() : variation ***
-- Testing multiple compression --
string(32) "764809aef15bb34cb73ad49ecb600d99"
string(32) "eba942bc2061f23ea8688cc5101872a4"
-===Done===
var_dump( bin2hex(gzdeflate($smallstring) ));
?>
-===Done===
--EXPECT--
*** Testing gzdeflate() : basic functionality ***
-- Compression level -1 --
-- Testing with no specified compression level --
string(58) "735428ce4dccc951282e29cacc4b5728c95748cecf2d284a2d2ee60200"
-===Done===
var_dump(gzdeflate($data, $level, $bad_encoding));
?>
-===Done===
--EXPECTF--
*** Testing gzdeflate() : error conditions ***
Warning: gzdeflate(): encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE in %s on line %d
bool(false)
-===Done===
var_dump(md5(gzdeflate($output)));
?>
-===Done===
--EXPECT--
*** Testing gzdeflate() : variation ***
-- Testing multiple compression --
string(32) "078554fe65e06f6ff01eab51cfc7ae9b"
string(32) "86b9f895ef1377da5269ec3cb2729f71"
-===Done===
var_dump(bin2hex(gzencode($smallstring, -1, FORCE_GZIP)));
?>
-===Done===
--EXPECTF--
*** Testing gzencode() : basic functionality ***
-- Compression level -1 --
-- Testing gzencode with mode specified --
string(94) "1f8b08000000000000%c%c735428ce4dccc951282e29cacc4b5728c95748cecf2d284a2d2ee60200edc4e40b1b000000"
-===Done===
var_dump(gzencode($data, $level, $bad_mode));
?>
-===Done===
--EXPECTF--
*** Testing gzencode() : error conditions ***
Warning: gzencode(): encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE in %s on line %d
bool(false)
-===Done===
$back = gzdecode(gzdecode($output));
var_dump($data === $back);
?>
-===Done===
--EXPECT--
*** Testing gzencode() : variation ***
-- Testing multiple compression --
bool(true)
-===Done===
var_dump(bin2hex(gzencode($output)));
?>
-===Done===
--EXPECT--
*** Testing gzencode() : variation ***
-- Testing multiple compression --
string(3658) "1f8b0800000000000003010e07f1f81f8b08000000000000036d574d6fe4c80dbdeb57d4ad2f3dfe01eb83e1ec22980e309b4562c067b64449159754dafab0b6e7d7e73d96da1e4c72184c4b2ab2c8f7c847fa25baabba98dc1a8b2b7c38bb324b713ee37f757f56cdc5c7f5b17b9d152f923b157c5ae335e0b75fedd0e2d781c6b98ea3a6ee05affe1dfc3a6527f8f09c52dcb38ba38bb5249934d6ecfe1e53a9ab76ff4c342cf2a64ed2028349fc9a8b139755685352acb82b9fbb67f8bade5cdcb698e1fcec94b7ceba3cb897e806cfc8114350dd1ebbdfa35b62d2478b0056d23ed809b9b95d696d91ce2aa97c911e3fa539c43f84c887554a4d125c9e63ff96711cc08c0866263cb37a0bbe2122ae8f6baecb2284abfb4ddf916db8354cddeef37c1afe5fa02fc7afb3db34f5b3acbdf2eb905490d8f38d7468d253a323d5ebb903760d7944d3b2024e834a99ddce77669bdd823cfbb8e899d4ad4c799677452e6029e80023a03b2374005590641f7d3877df2ad09f3c0e82a54d6a5644fd63049a37ed4bc362016fd9f51264f1e5c630727421ae930b7ed416e93e47b7c71a400390361ffbecb7561bb98f69b5da289e91becc27f08b3b724cb8704f9144d366431d0cb870c56b205deaa2e17636063761a911039fb7e4bf9f06c4f0aecd2ec80e8b41831ca7515e31286166458ea3ef71f2ce7cde2ae269c96d60525724a9c9170b713ed5750758f3cd2a361fc8b288fc92358ce884692e8ea0fe59bd969a0da2eed5831b715749eaae7178f3ebd30fb88c92105f367cce2c882955dc6bf8eca0d5d57540b3092894743ba0fd5b2dad021836191f1afc0bba14dde1642cb0b1aa6879c38907dcefa0720082b801bec61417469219175267dfa047df35b0bd1332001c28cdfafd3bcabe91e74368cdd8d8478e494c190e7ee90c67f2bde288e68ab6b15e883c995be4f8feb6c6dda4278e4f38578ddbdc7be36788daf0c3cb1d1819c73822f7000a0d1813fa94153b572315e51343b536bc64977dff163cebfd8418773261f524017e251fccc60ae29a5770ae097594d52e9c1229d87ce967a36401c46b69945afb249d101c9d420ffa9a123e232c20e76467d5d169202a2dd4c582949e013e745df7958d4b0cc4fd4377a737cd4feea7974070000f314d423e0634cb9a618fdf5dc64fd422181fd59c9230c9f6f9d18dc8fc23e9cccbc7188733b04aa57de83ebea0be3633cff5fa1ff83269be7f44f5a8d84550cc703255fd345dd402034d0b3e11a73ec6e3d4a77f4f685b614329f1b3132ae7af33d02e1e55e291fa6574b758d1f0200e7423dbc852211818043a7c9ce80aa9d59fce0401959f5ea2cf71fde90824f8c9192dbe9d329db143794675ddcf257dd7755273b67340414e3ccad12e3f661f8aad9cf9957dc1275d10a51d3934fa81e68dc6768fb8ee23e373936c8e13feab8b0f50d227f7af76f561fb0950f3d099bbc316c3892a42fb36806d8660e800fa4f43fd4b962d2097d71933a54b77ff948677848eb17bb3a88b621682cfb3bbb49cf42fed6b3944124ad8358ca688aa44dd5f2144c7c9ab16f25b9aca9654ef357ec9ad55c40d324d6cc3d9e3920b863c231d31a95d937fb5520f9c816c79b7dcecc593fb9593cc05a51ebb1eeddd5b49eb437769738d0f64adc579d372b8b7f7c0208487ee3915ebf5766e148ebd77cf4e01f3ec285047011e55838968b6494d517fe29224777b24dd3ddf933101695b102e87db805eef291b74dcfd91628fb2a53f93dbd2968ef2e598746c9204f89fba1f0246fc671610a0591806e46a1346f77c40d910a47c5e20ffb23f003c04b648327a4ed98032c1965bd35bb0044f5344248f56fdb99aa61d6451d68e33489a83bffbe6573541b2da5f64681ea12090f778b2075374778810f73965fa3626a9d41f4df2f83f7c34658cec921b5a9bde49dd5007ec882b02adc514f81aa85898b5cc98e1b137733c0a8789b7f5648d2d231b80bf74978f25d61ce08a8abd11801fd8f995e066676307192ff7641f1cc6e0dee68565b8b22ac3889cd067bf732754a6b270af1044c6a8776811a4f6d8bd0477a9f516064201b920b92d7cd4dc7eee13e6b3eb3528a82f9abb3f388ebe6a8f871393461b73816ec54c99d604174bc5a6801de13908f86aea6a7d0fea107d682bcf1ec348b83872e6b8a316ecd02eb8f8dc86a609bf59a2dd03f1dfa4079436d55e24617be1a2854d008b2b2b1705e2078a7f3946318df1c24f6bf70d4b456eca286ec2b585b28262cc048a098c3e2d5f325a92bb36f691afdc14c822da1b116c9c1c07bb362eb0a04b78834c812134230ebf2044ac2e3c0e3ad00f848dc5010f3bf917ec2fc700b7bf26dacea8440620e04f90f4d97d6dd77cfde8a05c7d3930f1e5811fb8ec5c70964dcc8187ec90e32fdd6b64eec7586413b7d55bed65c4cce39a9b6c15e70e9da94e53fc904e6286f01f5b5562c94211befbc23507e01b2a3865e2f45b5d7b591f290087a5605b82495b4e393f31aa5b37211ec40241a746d903c5eebf117a4d3ddb0d00007b64cbc70e070000"
-===Done===
var_dump(bin2hex(gzencode($data, -1, FORCE_DEFLATE)));
?>
-===DONE===
--EXPECT--
*** Testing gzencode() : variation ***
string(90) "1f8b080000000000000a735428ce4dccc951282e29cacc4b5728c95748cd4bce4f49e50200d7739de519000000"
string(90) "1f8b080000000000000a735428ce4dccc951282e29cacc4b5728c95748cd4bce4f49e50200d7739de519000000"
string(66) "789c735428ce4dccc951282e29cacc4b5728c95748cd4bce4f49e50200735808cd"
-===DONE===
var_dump(bin2hex(gzencode($data, -1, FORCE_DEFLATE)));
?>
-===DONE===
--EXPECT--
*** Testing gzencode() : variation ***
string(90) "1f8b0800000000000003735428ce4dccc951282e29cacc4b5728c95748cd4bce4f49e50200d7739de519000000"
string(90) "1f8b0800000000000003735428ce4dccc951282e29cacc4b5728c95748cd4bce4f49e50200d7739de519000000"
string(66) "789c735428ce4dccc951282e29cacc4b5728c95748cd4bce4f49e50200735808cd"
-===DONE===
?>
-===DONE===
--EXPECT--
-- test 1 --
bool(false)
bool(true)
reading 20 characters. eof should be true still
bool(true)
-===DONE===
}
unlink($filename);
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
gzeof(): supplied resource is not a valid stream resource
-===DONE===
unlink($filename);
rmdir($dirname);
?>
-===DONE===
--EXPECT--
array(3) {
[0]=>
[2]=>
string(17) "for all languages"
}
-===DONE===
unlink($filename);
rmdir($dirname);
?>
-===DONE===
--EXPECT--
array(3) {
[0]=>
[2]=>
string(17) "for all languages"
}
-===DONE===
var_dump(gzfile( $filename, $var ) );
}
?>
-===DONE===
--EXPECT--
array(6) {
[0]=>
string(39) "and I know that it descends down on me
"
}
-===DONE===
var_dump(gzfile( $filename, $var ) );
}
?>
-===DONE===
--EXPECT--
array(6) {
[0]=>
string(39) "and I know that it descends down on me
"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
array(1) {
[0]=>
string(28) "This is a file in script dir"
}
-===DONE===
var_dump(gzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: gzfile(): Filename cannot be empty in %s on line %d
bool(false)
Warning: gzfile(): Filename cannot be empty in %s on line %d
bool(false)
-===DONE===
var_dump(gzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: gzfile(10.5): failed to open stream: No such file or directory in %s on line %d
bool(false)
Warning: gzfile(0.5): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(gzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: gzfile(0): failed to open stream: No such file or directory in %s on line %d
bool(false)
Warning: gzfile(-2345): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(gzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: gzfile(string): failed to open stream: No such file or directory in %s on line %d
bool(false)
Warning: gzfile(hello world): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(gzfile( $filename, $var ) );
}
?>
-===DONE===
--EXPECT--
array(6) {
[0]=>
string(39) "and I know that it descends down on me
"
}
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
and I know that it descends down on me
characters counted=176
-===DONE===
}
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
and I know that it descends down on me
characters counted=176
-===DONE===
?>
-===DONE===
--EXPECT--
string(9) "When you'"
string(13) "re taught thr"
"
string(39) "and I know that it descends down on me
"
-===DONE===
var_dump(gzinflate($compressed, $short_len));
?>
-===DONE===
--EXPECTF--
*** Testing gzinflate() : error conditions ***
Warning: gzinflate(): data error in %s on line %d
bool(false)
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
*** Testing gzopen() : basic functionality ***
When you're taught through feelings
Destiny who cares
as it turns around
and I know that it descends down on me
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing gzopen() : basic functionality ***
testing mode -- w --
Warning: gzopen(): cannot open a zlib stream for reading and writing at the same time! in %s on line %d
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
*** Testing gzopen() : usage variation ***
This is a file in dir1
This is a file in working dir
This is a file in script dir
-===DONE===
}
}
?>
-===DONE===
--EXPECT--
*** Testing gzopen() : variation ***
created in working dir
Not created in dir1
created in working dir
Not created in dir1
-===DONE===
unlink($absfile);
unlink($relfile);
?>
-===DONE===
--EXPECT--
*** Testing gzopen() : variation ***
This is an absolute file
This is a relative file
-===DONE===
var_dump(gzread($h2, 50));
// deliberately do not close $h2
?>
-===DONE===
--EXPECT--
string(30) "When you're taught through fee"
string(10) "When you'r"
Destiny f"
string(50) "e taught through feelings
Destiny flying high abov"
-===DONE===
echo "\n";
unlink($file);
?>
-===DONE===
--EXPECT--
*** Testing gzopen() : variation ***
Here is some plain
text to be read
and displayed.
-===DONE===
echo "\n";
}
?>
-===DONE===
--EXPECTF--
*** Testing gzopen() : variation ***
mode=r+
Warning: gzopen(%s/004.txt.gz): failed to open stream: %s in %s on line %d
gzopen=bool(false)
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
and I know that it descends down on me
int(176)
int(0)
-===DONE===
echo "\n";
unlink($filename);
?>
-===DONE===
--EXPECT--
int(34)
int(10)
Here is the string to be written. Here is th
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
string(10) "When you'r"
string(14) "e taught throu"
string(46) "around
and I know that it descends down on me
"
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECTF--
string(10) "When you'r"
Warning: gzread(): Length parameter must be greater than 0 in %s on line %d
bool(false)
string(8) "ght thro"
-===DONE===
echo "\n";
unlink($filename);
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
bool(false)
Here is the string to be written.
-===DONE===
echo "first 20 characters=".gzread($h, 20)."\n";
gzclose($h);
?>
-===DONE===
--EXPECT--
test rewind before doing anything
bool(true)
int(0)
first 10 characters=When you'r
first 20 characters=When you're taught t
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
read to the end of the file, then rewind
bool(true)
bool(false)
int(0)
first 20 characters=When you're taught t
-===DONE===
unlink($f);
echo "\n";
?>
-===DONE===
--EXPECT--
bool(false)
The first string.The second string.
-===DONE===
var_dump(gzread($h, 10));
gzclose($h);
?>
-===DONE===
--EXPECT--
move to the 50th byte
int(0)
int(0)
tell=20
string(10) "hrough fee"
-===DONE===
gzclose($h);
unlink($f);
?>
-===DONE===
--EXPECT--
tell=23
tell=43
This is the first line.
string(40) "0000000000000000000000000000000000000000"
This is the second line.
-===DONE===
gzclose($h);
unlink($f);
?>
-===DONE===
--EXPECT--
This is the first line.
string(40) "0000000000000000000000000000000000000000"
This is the second line.
-===DONE===
var_dump(gzread($h, 10));
gzclose($h);
?>
-===DONE===
--EXPECT--
move to the 50th byte
int(0)
int(0)
tell=20
string(10) "hrough fee"
-===DONE===
var_dump(gzread($h, 10));
gzclose($h);
?>
-===DONE===
--EXPECT--
move to the 50th byte
int(0)
int(0)
tell=77
string(10) "hat you ca"
-===DONE===
gzclose($h);
unlink($f);
?>
-===DONE===
--EXPECT--
tell=23
tell=43
This is the first line.
string(40) "0000000000000000000000000000000000000000"
This is the second line.
-===DONE===
gzclose($h);
unlink($f);
?>
-===DONE===
--EXPECT--
tell=23
tell=43
This is the first line.
string(40) "0000000000000000000000000000000000000000"
This is the second line.
-===DONE===
var_dump(gzread($h, 10));
gzclose($h);
?>
-===DONE===
--EXPECTF--
move 40 bytes
tell=int(40)
tell=int(40)
eof=bool(false)
string(10) "iny flying"
-===DONE===
echo "\n";
unlink($f);
?>
-===DONE===
--EXPECTF--
tell=int(23)
move to the end of the file
reading the output file
This is the first line.This is the second line.
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
int(0)
int(7)
int(127)
int(142)
int(176)
-===DONE===
gzclose($h);
unlink($f);
?>
-===DONE===
--EXPECT--
int(0)
bytes written=7
tell=142
bytes written=1000
tell=1142
-===DONE===
echo "Result length is ". strlen(gzuncompress($compressed, $length)) . "\n";
?>
-===DONE===
--EXPECT--
*** Testing gzuncompress() : basic functionality ***
-- Calling gzuncompress() with max length of 3547 --
Result length is 3547
-===DONE===
var_dump(gzuncompress(123));
?>
-===DONE===
--EXPECTF--
*** Testing gzuncompress() : error conditions ***
Warning: gzuncompress(): data error in %s on line %d
bool(false)
-===DONE===
echo "\n";
unlink($filename);
?>
-===DONE===
--EXPECT--
int(34)
int(10)
Here is the string to be written. Here is th
-===DONE===
echo "\n";
unlink($filename);
?>
-===DONE===
--EXPECT--
int(0)
int(0)
-===DONE===
gzclose($h);
?>
-===DONE===
--EXPECT--
int(0)
string(10) "When you'r"
int(0)
-===DONE===
unlink($filename);
rmdir($dirname);
?>
-===DONE===
--EXPECT--
hello world
is a very common test
for all languages
int(52)
-===DONE===
unlink($filename);
rmdir($dirname);
?>
-===DONE===
--EXPECT--
hello world
is a very common test
for all languages
int(52)
-===DONE===
var_dump(readgzfile( $filename, $var ) );
}
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
as it turns around
and I know that it descends down on me
int(176)
-===DONE===
var_dump(readgzfile( $filename, $var ) );
}
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
as it turns around
and I know that it descends down on me
int(176)
-===DONE===
}
?>
-===DONE===
--EXPECT--
file content:This is a file in dir2
file content:This is a file in dir1
file content:This is a file in dir1
file content:This is a file in working dir
file content:This is a file in script dir
-===DONE===
var_dump(readgzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: readgzfile(): Filename cannot be empty in %s on line %d
bool(false)
Warning: readgzfile(): Filename cannot be empty in %s on line %d
bool(false)
-===DONE===
var_dump(readgzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: readgzfile(10.5): failed to open stream: No such file or directory in %s on line %d
bool(false)
Warning: readgzfile(0.5): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(readgzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: readgzfile(0): failed to open stream: No such file or directory in %s on line %d
bool(false)
Warning: readgzfile(-2345): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(readgzfile( $var , $use_include_path ) );
}
?>
-===DONE===
--EXPECTF--
Warning: readgzfile(string): failed to open stream: No such file or directory in %s on line %d
bool(false)
Warning: readgzfile(hello world): failed to open stream: No such file or directory in %s on line %d
bool(false)
-===DONE===
var_dump(readgzfile( $filename, $var ) );
}
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
as it turns around
and I know that it descends down on me
int(176)
-===DONE===
}
unlink($outputFileName);
?>
-===DONE===
--EXPECT--
OK: Copy identical
-===DONE===
}
unlink($outputFileName);
?>
-===DONE===
--EXPECT--
OK: Copy identical
-===DONE===
unlink($inputFileName);
unlink($outputFileName);
?>
-===DONE===
--EXPECT--
OK: Copy identical
-===DONE===
var_dump(opendir($srcFile));
var_dump(rmdir($srcFile));
?>
-===DONE===
--EXPECTF--
bool(false)
bool(false)
Warning: opendir(compress.zlib://%s/dir.gz): failed to open dir: not implemented in %s on line %d
bool(false)
bool(false)
-===DONE===
$contents = file($srcFile);
var_dump($contents);
?>
-===DONE===
--EXPECT--
array(6) {
[0]=>
string(39) "and I know that it descends down on me
"
}
-===DONE===
$contents = file_get_contents($srcFile);
echo $contents;
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
Destiny who cares
as it turns around
and I know that it descends down on me
-===DONE===
echo "\n";
unlink($outputFileName);
?>
-===DONE===
--EXPECT--
Here is some plain
text to be read
and displayed.
-===DONE===
$srcFile = "compress.zlib://$inputFileName";
readfile($srcFile);
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
Destiny who cares
as it turns around
and I know that it descends down on me
-===DONE===
fpassthru($h);
fclose($h);
?>
-===DONE===
--EXPECT--
When you're taught through feelings
Destiny flying high above
Destiny who cares
as it turns around
and I know that it descends down on me
-===DONE===
fpassthru($h);
fclose($h);
?>
-===DONE===
--EXPECTF--
file=compress.zlib://file://%s/004.txt.gz
Destiny who cares
as it turns around
and I know that it descends down on me
-===DONE===
rename($srcFile, 'something.tmp');
var_dump(file_exists($inputFileName));
?>
-===DONE===
--EXPECTF--
Warning: rename(): ZLIB wrapper does not support renaming in %s on line %d
bool(true)
-===DONE===
stat($srcFile);
lstat($srcFile);
?>
-===DONE===
--EXPECTF--
Warning: stat(): stat failed for compress.zlib://%s/004.txt.gz in %s on line %d
Warning: lstat(): Lstat failed for compress.zlib://%s/004.txt.gz in %s on line %d
-===DONE===
var_dump(fileatime($srcFile));
?>
-===DONE===
--EXPECTF--
file_exists=bool(false)
is_file=bool(false)
fileatime=
Warning: fileatime(): stat failed for compress.zlib://%s004.txt.gz in %s on line %d
bool(false)
-===DONE===
unlink($srcFile);
var_dump(file_exists($inputFileName));
?>
-===DONE===
--EXPECTF--
Warning: unlink(): ZLIB does not allow unlinking in %s on line %d
bool(true)
-===DONE===
echo "\n";
unlink($filename);
?>
-===DONE===
--EXPECT--
bool(true)
bool(true)
Here is the string to be written.Here is the string to be written.
-===DONE===
var_dump(flock($h, LOCK_SH));
gzclose($h);
?>
-===DONE===
--EXPECT--
bool(false)
-===DONE===
var_dump(fstat($h));
fclose($h);
?>
-===DONE===
--EXPECT--
bool(false)
-===DONE===
unlink($f2);
?>
-===DONE===
--EXPECTF--
Warning: ftruncate(): Can't truncate this stream! in %s on line %d
Warning: ftruncate(): Can't truncate this stream! in %s on line %d
-===DONE===
?>
-===DONE===
--EXPECTF--
no wrapper
array(7) {
["uri"]=>
string(%d) "compress.zlib://%s/004.txt.gz"
}
-===DONE===
var_dump(`"$php" -n -s -w -l`);
?>
-===DONE===
--EXPECT--
string(25) "No input file specified.
"
string(49) "No syntax errors detected in Standard input code
"
-===DONE===
passthru( "$php -n -q " . escapeshellarg( $test_file ) );
?>
-===DONE===
--CLEAN--
<?php
@unlink( __DIR__ . DIRECTORY_SEPARATOR ."apache_response_headers.test.php" );
["Content-type"]=>
string(24) "text/html; charset=UTF-8"
}
-===DONE===
unlink($fn);
?>
-===DONE===
--EXPECT--
bool(true)
string(3) "啊"
-===DONE===
var_dump(`"$php" -nd max_execution_time=500 -r 'var_dump(ini_get("max_execution_time"));'`);
?>
-===DONE===
--EXPECT--
string(16) "string(3) "111"
"
string(16) "string(3) "500"
"
-===DONE===
var_dump(`cat "$filename_txt" | "$php" -n -F "$filename"`);
?>
-===DONE===
--CLEAN--
<?php
@unlink(__DIR__."/010.test.php");
string(10) "test
hello"
"
-===DONE===
@unlink($argv_fl);
?>
-==DONE==
--EXPECTF--
string(%d) "array(%d) {
[0]=>
string(15) "flerbytesträng"
}
"
-==DONE==
var_dump(file_get_contents($out_fl));
?>
-==DONE==
--CLEAN--
<?php
$out_fl = __DIR__ . "\\argv_bug77111.txt";
?>
--EXPECTF--
string(57) "Ästhetik Æstetik Esthétique Estética Эстетика"
-==DONE==
var_dump(preg_match(",.+a[\\/].+[\\/]w.php_kartoffelbrei.dll.+,s", $out));
?>
-==DONE==
--EXPECT--
int(1)
-==DONE==
echo "Exception caught OK; continuing.\n";
}
?>
-==DONE==
--EXPECTF--
---> Invoke __call via simple method call.
object(A)#%d (0) {
object(B)#%d (0) {
}
Exception caught OK; continuing.
-==DONE==
echo "Exception caught OK; continuing.\n";
}
?>
-==DONE==
--EXPECTF--
Warning: The magic method __call() must have public visibility and cannot be static in %s on line 3
---> Invoke __call via simple method call.
object(B)#2 (0) {
}
Exception caught OK; continuing.
-==DONE==
var_dump($foo->bar->baz);
?>
-===DONE===
--EXPECT--
string(5) "Check"
string(5) "Check"
-===DONE===
var_dump($foo->bar->baz);
?>
-===DONE===
--EXPECTF--
AutoGen::__get
Test::__set
AutoGen::__get
Test::__get
string(5) "Check"
-===DONE===
?>
===DONE===
-<?php exit(0); ?>
--EXPECTF--
Fatal error: Class derived contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (derived::show) in %sabstract_derived.php on line %d
}
?>
-===DONE===
--EXPECT--
test::func()
call_user_func() expects parameter 1 to be a valid callback, cannot call abstract method test_base::func()
-===DONE===
var_dump($obj->a);
?>
-===DONE===
--EXPECTF--
array(4) {
[0]=>
[6]=>
string(9) "changed 6"
}
-===DONE===
var_dump($obj->a);
?>
-===DONE===
--EXPECTF--
array(4) {
[0]=>
[6]=>
string(9) "changed 6"
}
-===DONE===
var_dump($obj[2]);
?>
-===DONE===
--EXPECTF--
ObjectOne::offsetGet(1)
string(6) "fooBar"
Notice: Indirect modification of overloaded element of ObjectOne has no effect in %sarray_access_003.php on line 39
ObjectOne::offsetGet(2)
int(1)
-===DONE===
var_dump($obj[2]);
?>
-===DONE===
--EXPECTF--
ObjectOne::offsetGet(1)
string(6) "fooBar"
Notice: Indirect modification of overloaded element of ObjectOne has no effect in %sarray_access_004.php on line 39
ObjectOne::offsetGet(2)
int(1)
-===DONE===
var_dump($people[0]['name']);
?>
-===DONE===
--EXPECTF--
string(3) "Joe"
string(6) "JoeFoo"
Notice: Indirect modification of overloaded element of Peoples has no effect in %sarray_access_005.php on line 48
string(6) "JoeFoo"
-===DONE===
$a[] = 4;
$a->dump();
?>
-===DONE===
--EXPECT--
array(4) {
[0]=>
[3]=>
int(4)
}
-===DONE===
var_dump($people[0]['name']);
?>
-===DONE===
--EXPECTF--
string(3) "Foo"
string(6) "FooBar"
Notice: Indirect modification of overloaded element of Peoples has no effect in %sarray_access_008.php on line 44
string(3) "Foo"
-===DONE===
var_dump($people[0]['name']);
?>
-===DONE===
--EXPECTF--
string(3) "Foo"
string(6) "FooBar"
ArrayProxy::__construct(0)
ArrayProxy::offsetGet(0, name)
string(6) "BlaBla"
-===DONE===
var_dump($people[0]['name']);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
string(3) "Foo"
string(6) "FooBar"
ArrayReferenceProxy::__construct(Array)
ArrayReferenceProxy::offsetGet(Array, name)
string(6) "BlaBla"
-===DONE===
var_dump($people[0]['name']);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
string(3) "Foo"
string(6) "FooBar"
ArrayAccessReferenceProxy::__construct(0)
ArrayAccessReferenceProxy::offsetGet(0, name)
string(6) "BlaBla"
-===DONE===
?>
===DONE===
-<?php exit(0); ?>
--EXPECTF--
Notice: Indirect modification of overloaded element of ArrayAccessImpl has no effect in %sarray_access_012.php on line 24
echo "Caught in " . $e->getMessage() . "()\n";
}
?>
-===DONE===
--EXPECT--
Caught in Test::offsetExists()
Caught in Test::offsetGet()
Caught in Test::offsetSet()
Caught in Test::offsetUnset()
-===DONE===
var_dump(class_exists('autoload_root'));
?>
-===DONE===
--EXPECT--
autoload(autoload_root)
bool(true)
-===DONE===
var_dump(get_class_methods('autoload_root'));
?>
-===DONE===
--EXPECT--
autoload(autoload_root)
array(1) {
[0]=>
string(12) "testFunction"
}
-===DONE===
var_dump(class_exists('autoload_derived'));
?>
-===DONE===
--EXPECT--
autoload(autoload_root)
autoload(autoload_derived)
bool(true)
-===DONE===
var_dump(class_exists('autoload_derived'));
?>
-===DONE===
--EXPECT--
bool(false)
bool(false)
autoload(autoload_root)
autoload(autoload_derived)
bool(true)
-===DONE===
unset($o);
?>
-===DONE===
--EXPECTF--
bool(false)
bool(false)
autoload(autoload_derived)
object(autoload_derived)#%d (0) {
}
-===DONE===
var_dump(class_exists('autoload_implements', false));
?>
-===DONE===
--EXPECTF--
bool(false)
bool(false)
bool(true)
bool(true)
bool(true)
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test::__construct(Hello)
Caught Exception(Hello)
-===DONE===
}
?>
-===DONE===
--EXPECT--
FailClass::__destruct
Caught: FailClass
FatalException::__construct
FailClass::__destruct
Caught Exception: FailClass
-===DONE===
unset($obj); // Derived::__destruct is being called not Base::__destruct
?>
-===DONE===
--EXPECT--
Derived::__destruct
-===DONE===
echo $t->test('if_e');
?>
-===DONE===
--EXPECT--
class_a
is_a(class_a, if_a) yes
is_a(class_g, if_c) yes
is_a(class_g, if_d) yes
is_a(class_g, if_e) no
-===DONE===
}
?>
-===DONE===
--EXPECT--
0: foo
1: bar
0: foo
1: bar
2: baz
-===DONE===
$t->x++;
}
?>
-===DONE===
--EXPECT--
Caught in Test::rewind()
Caught in Test::current()
Current
Caught in Test::next()
Caught in Test::valid()
-===DONE===
$c->p = 'this will fail';
var_dump($c);
?>
-==Done==
+===DONE===
--EXPECTF--
Unset and recreate a superclass's private property:
object(D)#%d (1) {
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
==========
string(6) "String"
Test::__construct()
Test::serialize()
Exception: Test::serialize() must return a string or NULL
-===DONE===
//$c->y = 1; // Fatal error, tested in static_properties_003_error3.phpt
//$c->y =& $ref; // Fatal error, tested in static_properties_003_error4.phpt
?>
-==Done==
--EXPECTF--
--> Access visible static prop like instance prop:
bool(false)
--> Access non-visible static prop like instance prop:
bool(false)
-==Done==
echo "\n--> Access non-visible static prop like instance prop:\n";
unset($c->y);
?>
-==Done==
+===DONE===
--EXPECTF--
--> Access non-visible static prop like instance prop:
echo "\n--> Access non-visible static prop like instance prop:\n";
echo $c->y;
?>
-==Done==
+===DONE===
--EXPECTF--
--> Access non-visible static prop like instance prop:
echo "\n--> Access non-visible static prop like instance prop:\n";
$c->y = 1;
?>
-==Done==
+===DONE===
--EXPECTF--
--> Access non-visible static prop like instance prop:
echo $e, "\n";
}
?>
-==Done==
--EXPECTF--
--> Access non-visible static prop like instance prop:
Error: Cannot access protected property C::$y in %s:%d
Stack trace:
#0 {main}
-==Done==
D::$p =& $ref;
var_dump(C::$p, D::$p, E::$p);
?>
-==Done==
--EXPECT--
Inherited static properties refer to the same value across classes:
string(8) "original"
string(11) "changed.one"
string(11) "changed.one"
string(11) "changed.one"
-==Done==
endswitch;
?>
-===DONE===
--EXPECT--
If: 11
While: 12346789
For: 0123401234
Switch: 1
-===DONE===
}
?>
-===DONE===
-<?php exit(0); ?>
--EXPECT--
string(15) "Error2Exception"
string(5) "fopen"
-===DONE===
}
?>
-===DONE===
--EXPECT--
Catchable
-===DONE===
echo $b[0]."\n";
}
?>
-===DONE===
--EXPECT--
0
1
-===DONE===
test(1.7e-1000);
?>
-===DONE===
-<?php exit(0); ?>
--EXPECTF--
1.7000000000000001E+300
float(1.7E+300)
0
0
------
-===DONE===
foreach($var['nosuchkey'] as $v) {
}
?>
-===DONE===
--EXPECTF--
Warning: Illegal string offset 'nosuchkey' in %sbug29566.php on line %d
Warning: Invalid argument supplied for foreach() in %sbug29566.php on line %d
-===DONE===
}
?>
-===DONE===
--EXPECT--
1
-===DONE===
(float)"infusorian"
);
?>
-==DONE==
--EXPECT--
float(0)
float(0)
float(0)
float(0)
-==DONE==
var_dump($obj5 == $obj3);
?>
-===DONE===
--EXPECT--
Simple test for standard compare object handler
bool(false)
bool(false)
bool(false)
-===DONE===
var_dump($obj1 == $obj2);
?>
-===DONE===
--EXPECT--
Simple test comparing two objects with different compare callback handler
bool(false)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
object(MealIterator)#%d (2) {
["pos":"MealIterator":private]=>
Notice: Undefined offset: 3 in %s on line %d
--> MealIterator::valid (4)
-===DONE===
?>
-===DONE===
--EXPECTF--
object(EuropeanMeals)#%d (2) {
["storedEnglishMealIterator":"EuropeanMeals":private]=>
--> EnglishMealIterator::valid (3)
--> EnglishMealIterator::next (3)
--> EnglishMealIterator::valid (4)
-===DONE===
f("bad4");
?>
-===DONE===
--EXPECT--
30: Objects returned by bad1::getIterator() must be traversable or implement interface Iterator
30: Objects returned by bad2::getIterator() must be traversable or implement interface Iterator
30: Objects returned by bad3::getIterator() must be traversable or implement interface Iterator
30: Objects returned by bad4::getIterator() must be traversable or implement interface Iterator
-===DONE===
}
?>
-===DONE===
--EXPECT--
-----( A1: )-----
--> EnglishMealIterator::rewind (0)
meal 2 => tea
--> EnglishMealIterator::next (2)
--> EnglishMealIterator::valid (3)
-===DONE===
unset($t);
?>
-===DONE===
--EXPECT--
c::getIterator
c_iter::__construct
double:2:0
c_iter::next
c_iter::valid = false
-===DONE===
}
var_dump($myE);
?>
-===DONE===
--EXPECTF--
Iterate over various generations from within overridden methods:
["e":"C":private]=>
string(10) "Original e"
}
-===DONE===
var_dump($obj);
?>
-===DONE===
--EXPECTF--
Directly changing object values.
string(10) "Original a"
["e":"C":private]=>
string(10) "Original e"
}
-===DONE===
?>
-===DONE===
--EXPECTF--
Removing the current element from an iterated object.
string(10) "Original a"
["e"]=>
string(10) "Original e"
}
-===DONE===
}
?>
-===DONE===
--EXPECT--
1
2
3
4
5
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 + 0 ---
int(9223372036854775807)
int(0)
--- testing: 9223372036854775807 + -9.2233720368548E+18 ---
float(0)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' + '0' ---
int(0)
float(3.4)
--- testing: 'a5.9' + 'a5.9' ---
int(0)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 & 0 ---
int(0)
int(1)
--- testing: 9223372036854775807 & -9.2233720368548E+18 ---
int(0)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' & '0' ---
string(2) "30"
string(8) "21242421"
--- testing: 'a5.9' & 'a5.9' ---
string(8) "61352e39"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
int(-9223372036854775808)
int(9223372036854775806)
--- testing: -9.2233720368548E+18 ---
int(9223372036854775807)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: '0' ---
string(2) "cf"
string(8) "ccd1cb9e"
--- testing: 'a5.9' ---
string(8) "9ecad1c6"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 | 0 ---
int(9223372036854775807)
int(-1)
--- testing: 9223372036854775807 | -9.2233720368548E+18 ---
int(-1)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' | '0' ---
string(2) "30"
string(8) "733f3e79"
--- testing: 'a5.9' | 'a5.9' ---
string(8) "61352e39"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 << 0 ---
int(9223372036854775807)
Exception: Bit shift by negative number
--- testing: 9223372036854775807 << -9.2233720368548E+18 ---
Exception: Bit shift by negative number
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: '0' << '0' ---
int(0)
int(0)
--- testing: 'a5.9' << 'a5.9' ---
int(0)
-===DONE===
var_dump("56" << "2");
?>
-===DONE===
--EXPECT--
int(12)
int(68)
int(224)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' << '0' ---
int(0)
int(0)
--- testing: 'a5.9' << 'a5.9' ---
int(0)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 >> 0 ---
int(9223372036854775807)
Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> -9.2233720368548E+18 ---
Exception: Bit shift by negative number
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' >> '0' ---
int(0)
int(0)
--- testing: 'a5.9' >> 'a5.9' ---
int(0)
-===DONE===
var_dump("56" >> "2");
?>
-===DONE===
--EXPECT--
int(12)
int(17)
int(14)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ^ 0 ---
int(9223372036854775807)
int(-2)
--- testing: 9223372036854775807 ^ -9.2233720368548E+18 ---
int(-1)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' ^ '0' ---
string(2) "00"
string(8) "521b1a58"
--- testing: 'a5.9' ^ 'a5.9' ---
string(8) "00000000"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 / 0 ---
float(INF)
int(-1)
--- testing: 9223372036854775807 / -9.2233720368548E+18 ---
float(-1)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' / '0' ---
float(NAN)
float(0)
--- testing: 'a5.9' / 'a5.9' ---
float(NAN)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 % 0 ---
Exception: Modulo by zero
int(0)
--- testing: 9223372036854775807 % -9.2233720368548E+18 ---
int(9223372036854775807)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' % '0' ---
Exception: Modulo by zero
int(0)
--- testing: 'a5.9' % 'a5.9' ---
Exception: Modulo by zero
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 * 0 ---
int(0)
float(-8.5070591730235E+37)
--- testing: 9223372036854775807 * -9.2233720368548E+18 ---
float(-8.5070591730235E+37)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' * '0' ---
int(0)
float(0)
--- testing: 'a5.9' * 'a5.9' ---
int(0)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
int(-9223372036854775807)
int(9223372036854775807)
--- testing: -9.2233720368548E+18 ---
float(9.2233720368548E+18)
-===DONE===
}
?>
-===DONE===
--EXPECTF--
--- testing: '0' ---
int(0)
Warning: A non-numeric value encountered in %s on line %d
int(0)
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
echo "Test Passed\n";
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
echo "Test Passed\n";
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
echo "Test Passed\n";
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
echo "Test Passed\n";
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
echo "Test Passed\n";
}
?>
-===DONE===
--EXPECT--
Test Passed
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
int(9223372036854775806)
int(-9223372036854775808)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: '0' ---
int(-1)
string(4) "3.4a"
--- testing: 'a5.9' ---
string(4) "a5.9"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(9.2233720368548E+18)
int(-9223372036854775806)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: '0' ---
int(1)
string(4) "3.4b"
--- testing: 'a5.9' ---
string(4) "a5.0"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
int(9223372036854775806)
int(-9223372036854775808)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: '0' ---
int(-1)
string(4) "3.4a"
--- testing: 'a5.9' ---
string(4) "a5.9"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 ---
float(9.2233720368548E+18)
int(-9223372036854775806)
--- testing: -9.2233720368548E+18 ---
float(-9.2233720368548E+18)
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: '0' ---
int(1)
string(3) "20a"
--- testing: '99z' ---
string(4) "100a"
-===DONE===
}
?>
-===DONE===
--EXPECT--
--- testing: 9223372036854775807 - 0 ---
int(9223372036854775807)
float(1.844674407371E+19)
--- testing: 9223372036854775807 - -9.2233720368548E+18 ---
float(1.844674407371E+19)
-===DONE===
?>
-===DONE===
--EXPECT--
--- testing: '0' - '0' ---
int(0)
float(-3.4)
--- testing: 'a5.9' - 'a5.9' ---
int(0)
-===DONE===
$stack = $original;
var_dump(array_shift(array_shift($stack)));
?>
-===DONE===
--EXPECTF--
Notice: Only variables should be passed by reference in %s on line %d
string(3) "two"
Notice: Only variables should be passed by reference in %s on line %d
string(3) "one"
-===DONE===
test("9.9.");
test("9.9.9");
?>
-===DONE===
--EXPECT--
--> Testing ..9:
int(0)
int(9)
float(9.9)
bool(true)
-===DONE===
echo "\n";
?>
-===DONE===
--EXPECT--
firstfirstfirstfirstsecondsecondsecondsecondsecond
-===DONE===
}
?>
-==DONE==
--EXPECT--
--> Use callback 'return_empty_string':
--> Use callback 'return_zero':
0
-==DONE==
$str = ob_get_contents();
var_dump($str);
?>
-==DONE==
--EXPECT--
[callback:1]This call will obtain the content:
string(35) "This call will obtain the content:
"
-==DONE==