feat: Add manual payout system for countries without Stripe Global Payouts

This commit is contained in:
kbe
2025-09-17 08:35:20 +02:00
parent 3c1e17c2af
commit c74140c431
12 changed files with 375 additions and 28 deletions

View File

@@ -135,6 +135,17 @@ class Promoter::PayoutsControllerTest < ActionDispatch::IntegrationTest
assert_flash :alert, /Event not eligible for payout/
end
test "show renders manual payout details correctly" do
sign_in @user
@user.update(is_professionnal: true)
payout = Payout.create!(user: @user, event: @event, amount_cents: 1000, fee_cents: 100, status: :completed, stripe_payout_id: "MANUAL_abc123")
get promoter_payout_url(payout)
assert_response :success
assert_match "Manual Payout ID", @response.body
assert_match "Manual Transfer", @response.body
end
# Create failure: validation errors
test "create payout fails with validation errors" do
sign_in @user