def METHOD_NAME(self, key_id, user, operations, grant, error_code=None):
    expected_params = {
        'KeyId': key_id, 'GranteePrincipal': user, 'Operations': operations}
    response = grant
    self._stub_bifurcator(
        'create_grant', expected_params, response, error_code=error_code)