function FeedParserTest::testHtmlEntitiesSample

Same name in other branches
  1. 9 core/modules/aggregator/tests/src/Functional/FeedParserTest.php \Drupal\Tests\aggregator\Functional\FeedParserTest::testHtmlEntitiesSample()

Tests a feed that uses HTML entities in item titles.

File

core/modules/aggregator/tests/src/Functional/FeedParserTest.php, line 83

Class

FeedParserTest
Tests the built-in feed parser with valid feed samples.

Namespace

Drupal\Tests\aggregator\Functional

Code

public function testHtmlEntitiesSample() {
    $feed = $this->createFeed($this->getHtmlEntitiesSample());
    $feed->refreshItems();
    $this->drupalGet('aggregator/sources/' . $feed->id());
    $this->assertSession()
        ->statusCodeEquals(200);
    $this->assertRaw("Quote" Amp&");
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.