コード例 #1
0
ファイル: SelectorTest.php プロジェクト: adamblake/SimpleDb
 /**
  * @covers adamblake\SimpleDb\Selector\Selector::unQuote
  */
 public function testUnQuote()
 {
     $test = array("'single'", "''double''", "'\"mixed double\"'", "'multiple' words 'outer'", "multiple 'words' \"quoted\" inner");
     $this->assertEquals('single', Selector::unQuote($test[0]));
     $this->assertEquals('double', Selector::unQuote($test[1]));
     $this->assertEquals('mixed double', Selector::unQuote($test[2]));
     $this->assertEquals("multiple' words 'outer", Selector::unQuote($test[3]));
     $this->assertEquals("multiple 'words' \"quoted\" inner", Selector::unQuote($test[4]));
 }