/**
  * Generated the site map
  *
  * @param  string $websiteUrl
  * @return string
  */
 protected function generateSiteMap()
 {
     $urls = array();
     $siteName = $this->configurationHandler->siteName();
     foreach ($this->pagesCollectionParser->pages() as $page) {
         foreach ($page["seo"] as $seo) {
             $urls[] = array('href' => $siteName . '/' . $seo["permalink"], 'frequency' => $seo["sitemap_frequency"], 'priority' => $seo["sitemap_priority"]);
         }
     }
     return $this->twig->render('RedKiteCms/Resources/views/Sitemap/sitemap.html.twig', array('urls' => $urls));
 }
 public function testParse()
 {
     $this->init();
     $configurationHandler = $this->initConfigurationHandler();
     $pageCollectionParser = new PagesCollectionParser($configurationHandler);
     $pageCollectionParser->parse();
     $this->pagesTest($pageCollectionParser);
     $this->pageTest($pageCollectionParser);
     $this->permalinksByLanguageTest($pageCollectionParser);
     $this->sitemapTest($pageCollectionParser);
 }