public function testAttribute() { $expected = 'B'; $this->webElement->shouldReceive('hasAttribute')->with('A')->once()->andReturn($expected); $this->webElement->shouldReceive('getAttribute')->with('A')->once()->andReturn($expected); $this->assertSame($expected, $this->typifiedElement->hasAttribute('A')); $this->assertSame($expected, $this->typifiedElement->getAttribute('A')); }