public function testHasButton() { $this->mockNamedFinder('//button', array('button1', 'button2', 'button3'), array('button', 'some button')); $this->assertTrue($this->document->hasButton('some button')); $this->assertFalse($this->document->hasButton('some button')); }