public function testKeyPress() { $node = new NodeElement('elem', $this->session); $this->driver->expects($this->once())->method('keyPress')->with('elem', 'key'); $node->keyPress('key'); }