function XMLSitemapEnginesFunctionalTest::testSubmitSitemaps in XML sitemap 6.2
Same name and namespace in other branches
- 7.2 xmlsitemap_engines/tests/xmlsitemap_engines.test \XMLSitemapEnginesFunctionalTest::testSubmitSitemaps()
File
- xmlsitemap_engines/
tests/ xmlsitemap_engines.test, line 44 - Tests for the xmlsitemap_engines module.
Class
- XMLSitemapEnginesFunctionalTest
- @file Tests for the xmlsitemap_engines module.
Code
function testSubmitSitemaps() {
$sitemaps = array();
$sitemap = new stdClass();
$sitemap->uri = array(
'path' => 'http://example.com/sitemap.xml',
'options' => array(),
);
$sitemaps[] = $sitemap;
$sitemap = new stdClass();
$sitemap->uri = array(
'path' => 'http://example.com/sitemap-2.xml',
'options' => array(),
);
$sitemaps[] = $sitemap;
xmlsitemap_engines_submit_sitemaps($this->submit_url, $sitemaps);
$this
->assertWatchdogMessage(array(
'type' => 'xmlsitemap',
'message' => 'Recieved ping for @sitemap.',
'variables' => array(
'@sitemap' => 'http://example.com/sitemap.xml',
),
));
$this
->assertWatchdogMessage(array(
'type' => 'xmlsitemap',
'message' => 'Recieved ping for @sitemap.',
'variables' => array(
'@sitemap' => 'http://example.com/sitemap-2.xml',
),
));
}