def testDelete(self, getStubMock): stubMock = mock.Mock() stubMock.Delete.return_value = host_pb2.OwnerDeleteResponse() getStubMock.return_value = stubMock owner = opencue.wrappers.owner.Owner( host_pb2.Owner(id=TEST_OWNER_ID, name=TEST_OWNER_NAME)) owner.delete() stubMock.Delete.assert_called_with( host_pb2.OwnerDeleteRequest(owner=owner.data), timeout=mock.ANY)
def delete(self): """Delete the owner record""" self.stub.Delete(host_pb2.OwnerDeleteRequest(owner=self.data), timeout=Cuebot.Timeout)