/** * */ public function testDumpLocation() { $locationEntity = new LocationEntity(); $locationEntity->setLocation('http://test.com/'); $locationEntity->setLastmod(new \DateTime('2015-09-10')); $this->siteMapEntity->addLocation($locationEntity); $this->assertRegExp('/\\<url\\>\\<loc\\>http\\:\\/\\/test\\.com\\/\\<\\/loc\\>\\<lastmod\\>2015\\-09\\-10\\<\\/lastmod\\>\\<\\/url\\>/', $this->siteMapEntity->getXml()); }
/** * */ public function testLastmod() { $this->locationEntity->setLastmod(new \DateTime('2015-09-10')); $this->assertRegExp('/\\<lastmod\\>2015-09-10\\<\\/lastmod\\>/', $this->locationEntity->getXml()); }