Subversion-Projekte lars-tiefland.php_share

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
--TEST--
2
bug 3298 regression test
3
--FILE--
4
<?php
5
require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . 'setup.php.inc';
6
$datasrc = dirname(__FILE__) . '/bug3298.xml';
7
$root = $config->parseConfig($datasrc, 'XML');
8
 
9
$configArray = $root->toArray('PHParray');
10
$config2 = new Config();
11
$root2 = $config2->parseConfig(current($configArray), 'PHParray');
12
 
13
if ($root2->writeDatasrc('new_config.xml', 'XML')) {
14
   $file = file_get_contents("new_config.xml");
15
} else {
16
   echo "error updating XML";
17
}
18
 
19
if ($phpt->assertNoErrors('problem!')) {
20
   $phpt->assertEquals( file_get_contents($datasrc), $file, "XML doesn't match");
21
}
22
echo 'tests done';
23
?>
24
--CLEAN--
25
<?php
26
unlink('new_config.xml');
27
?>
28
--EXPECT--
29
tests done