You are here

public function SimplesitemapTest::testSetBundleSettingsDefaults in Simple XML sitemap 8.2

Same name and namespace in other branches
  1. 8.3 tests/src/Functional/SimplesitemapTest.php \Drupal\Tests\simple_sitemap\Functional\SimplesitemapTest::testSetBundleSettingsDefaults()
  2. 4.x tests/src/Functional/SimplesitemapTest.php \Drupal\Tests\simple_sitemap\Functional\SimplesitemapTest::testSetBundleSettingsDefaults()

Test default settings of bundles.

File

tests/src/Functional/SimplesitemapTest.php, line 163

Class

SimplesitemapTest
Tests Simple XML sitemap functional integration.

Namespace

Drupal\Tests\simple_sitemap\Functional

Code

public function testSetBundleSettingsDefaults() {
  $this->generator
    ->setBundleSettings('node', 'page')
    ->removeCustomLinks()
    ->generateSitemap('nobatch');
  $this
    ->drupalGet('sitemap.xml');
  $this
    ->assertSession()
    ->responseContains('node/' . $this->node
    ->id());
  $this
    ->assertSession()
    ->responseContains('0.5');
  $this
    ->assertSession()
    ->responseNotContains('changefreq');
}