/**
  *
  */
 public function testNewsCollection()
 {
     $newsEntity = new NewsEntity();
     $newsEntity->setPublicationName('test');
     $newsEntity->setPublicationLanguage('en');
     $this->locationEntity->addNews($newsEntity);
     $this->assertRegExp('/\\<news\\:news\\>/', $this->locationEntity->getXml());
     $this->assertRegExp('/\\<news\\:publication\\>/', $this->locationEntity->getXml());
     $this->assertRegExp('/\\<news\\:name\\>test\\<\\/news\\:name\\>/', $this->locationEntity->getXml());
     $this->assertRegExp('/\\<news\\:language\\>en\\<\\/news\\:language\\>/', $this->locationEntity->getXml());
     $this->assertRegExp('/\\<\\/news\\:publication\\>/', $this->locationEntity->getXml());
     $this->assertRegExp('/\\<\\/news\\:news\\>/', $this->locationEntity->getXml());
 }
Пример #2
0
 /**
  *
  */
 public function setUp()
 {
     $this->newsEntity = new NewsEntity();
     $this->newsEntity->setPublicationName('test');
     $this->newsEntity->setPublicationLanguage('en');
 }