Example #1
0
 public function testDetectRelationFromConfigInstancePropertyOfActivePage()
 {
     $active = $this->_helper->findOneByLabel('Page 2');
     $active->addRel('example', new Zend_Config(array('uri' => 'http://www.example.com/', 'label' => 'An example page')));
     $found = $this->_helper->findRelExample($active);
     $expected = array('type' => 'Zend_Navigation_Page_Uri', 'href' => 'http://www.example.com/', 'label' => 'An example page');
     $actual = array('type' => get_class($found), 'href' => $found->getHref(), 'label' => $found->getLabel());
     $this->assertEquals($expected, $actual);
 }