mirror of
https://github.com/php/php-src.git
synced 2024-11-29 04:46:07 +08:00
add test
This commit is contained in:
parent
35ce5db25e
commit
e43a77d84c
28
ext/simplexml/tests/bug36611.phpt
Normal file
28
ext/simplexml/tests/bug36611.phpt
Normal file
@ -0,0 +1,28 @@
|
||||
--TEST--
|
||||
Bug #36611 (assignment to SimpleXML object attribute changes argument type to string)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$xml_str = <<<EOD
|
||||
<?xml version="1.0" encoding="ISO-8859-1" ?>
|
||||
<c_fpobel >
|
||||
<pos >
|
||||
<pos/>
|
||||
</pos>
|
||||
</c_fpobel>
|
||||
EOD;
|
||||
|
||||
$xml = simplexml_load_string ($xml_str) ;
|
||||
|
||||
$val = 1;
|
||||
|
||||
var_dump($val);
|
||||
$obj->pos["act_idx"] = $val;
|
||||
var_dump($val) ;
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
int(1)
|
||||
int(1)
|
||||
Done
|
Loading…
Reference in New Issue
Block a user