/** * Should convert specials chars, & encode in utf8. */ public function testQuoteXMLChars() { $ops = new Ops(); $data = 'This is my & < > \' " string'; $result = $ops->_quoteXMLChars($data); /// chars should be converted $this->assertEquals($result, 'This is my & < > ' " string'); // should be utf8 $this->assertTrue(mb_check_encoding($result, 'UTF-8')); }