Пример #1
0
 /**
  * @depends	testInitialState
  * @return	null
  */
 public function testAddGetCssTagAsStrings()
 {
     $file1 = 'myfile.css';
     $file2 = 'myOtherfile.css';
     $file3 = 'yourfile.css';
     $tag1 = $this->factory->createLinkTag($file1);
     $tag2 = $this->factory->createLinkTag($file2);
     $tag3 = $this->factory->createLinkTag($file3);
     $this->assertEquals(0, $this->head->getCssTagCount());
     $this->assertSame($this->head, $this->head->addCssTag($file1));
     $this->assertEquals(1, $this->head->getCssTagCount());
     $expected = array($tag1);
     $this->assertEquals($expected, $this->head->getCssTags());
     $this->assertSame($this->head, $this->head->addCssTag($file2));
     $this->assertEquals(2, $this->head->getCssTagCount());
     $expected = array($tag1, $tag2);
     $this->assertEquals($expected, $this->head->getCssTags());
     $this->assertSame($this->head, $this->head->addCssTag($file3));
     $this->assertEquals(3, $this->head->getCssTagCount());
     $expected = array($tag1, $tag2, $tag3);
     $this->assertEquals($expected, $this->head->getCssTags());
 }