protected function XMLSitemapTestHelper::assertNoSitemapLink in XML sitemap 7.2
Same name and namespace in other branches
- 6.2 xmlsitemap.test \XMLSitemapTestHelper::assertNoSitemapLink()
Assert No Sitemap Link.
3 calls to XMLSitemapTestHelper::assertNoSitemapLink()
- XMLSitemapCustomFunctionalTest::testCustomFileLinks in xmlsitemap_custom/
xmlsitemap_custom.test - Test adding files as custom links.
- XMLSitemapCustomFunctionalTest::testCustomLinks in xmlsitemap_custom/
xmlsitemap_custom.test - Test Custom Links.
- XMLSitemapNodeFunctionalTest::testCron in xmlsitemap_node/
xmlsitemap_node.test - Test the import of old nodes via cron.
File
- ./
xmlsitemap.test, line 124 - Unit tests for the xmlsitemap.
Class
- XMLSitemapTestHelper
- Helper test class with some added functions for testing.
Code
protected function assertNoSitemapLink($entity_type, $entity_id = NULL) {
if (is_array($entity_type)) {
$links = xmlsitemap_link_load_multiple($entity_type);
$link = $links ? reset($links) : FALSE;
}
else {
$link = xmlsitemap_link_load($entity_type, $entity_id);
}
$this
->assertFalse($link, 'Link not loaded.');
return $link;
}