Is there a way in phpUnit to test if for example a certain css file is loaded?
In other 开发者_开发技巧words, i want to check if a css file is loaded (if possible). I want to make sure the HMTL output has a style tag with a certain css file.
You can do it as Foe example the page source will display the css file as
<style src="mycss.css" type="text/css"></style>
Then following statement will check that the element present or not
$this->assertTrue($this->isElementPresent("//style[@src='mycss.css']"));
精彩评论