You are here

public function CrawlerTest::testAddXmlContentCharset in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/dom-crawler/Tests/CrawlerTest.php \Symfony\Component\DomCrawler\Tests\CrawlerTest::testAddXmlContentCharset()

@covers Symfony\Component\DomCrawler\Crawler::addXmlContent

File

vendor/symfony/dom-crawler/Tests/CrawlerTest.php, line 172

Class

CrawlerTest

Namespace

Symfony\Component\DomCrawler\Tests

Code

public function testAddXmlContentCharset() {
  $crawler = new Crawler();
  $crawler
    ->addXmlContent('<html><div class="foo">Tiếng Việt</div></html>', 'UTF-8');
  $this
    ->assertEquals('Tiếng Việt', $crawler
    ->filterXPath('//div')
    ->text());
}