Skip to content
Snippets Groups Projects
Commit df6e580d authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Qual: Add phpunit for dolexplodeintoarray function

parent ce34c01b
No related branches found
No related tags found
No related merge requests found
...@@ -702,5 +702,21 @@ class FunctionsLibTest extends PHPUnit_Framework_TestCase ...@@ -702,5 +702,21 @@ class FunctionsLibTest extends PHPUnit_Framework_TestCase
$this->assertEquals(0,$vat1); $this->assertEquals(0,$vat1);
$this->assertEquals(0,$vat2); $this->assertEquals(0,$vat2);
} }
/**
* testDolExplodeIntoArray
*
* @return void
*/
public function testDolExplodeIntoArray()
{
$stringtoexplode='AA=B/B.CC=.EE=FF.HH=GG;.';
$tmp=dolExplodeIntoArray($stringtoexplode,'.','=');
print __METHOD__." tmp=".json_encode($tmp)."\n";
$this->assertEquals('{"AA":"B\/B","CC":"","EE":"FF","HH":"GG;"}',json_encode($tmp));
}
} }
?> ?>
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment