public function testGetPrimaryKey() { $this->_client->expects($this->once())->method('getPrimaryKey')->will($this->returnValue('id2')); $model = new Kwf_Model_Service(array('client' => $this->_client)); $pk = $model->getPrimaryKey(); $this->assertEquals('id2', $pk); }