def METHOD_NAME(
    mock_void_payment,
    staff_api_client,
    permission_group_manage_orders,
    payment_txn_preauth,
):
    permission_group_manage_orders.user_set.add(staff_api_client.user)
    msg = "Oops! Something went wrong."
    order = payment_txn_preauth.order
    order_id = graphene.Node.to_global_id("Order", order.id)
    variables = {"id": order_id}
    mock_void_payment.side_effect = ValueError(msg)
    response = staff_api_client.post_graphql(ORDER_VOID, variables)
    content = get_graphql_content(response)
    errors = content["data"]["orderVoid"]["errors"]
    assert errors[0]["field"] == "payment"
    assert errors[0]["message"] == msg
    order_errors = content["data"]["orderVoid"]["errors"]
    assert order_errors[0]["code"] == OrderErrorCode.PAYMENT_ERROR.name
    mock_void_payment.assert_called_once()