build_stripe_client() no longer degrades to the mock on absent config. Mock is selected only on explicit opt-in (mock=True or SAAS_STRIPE_MODE=mock); with mode unset/live, missing STRIPE_SECRET_KEY / STRIPE_WEBHOOK_SECRET raise StripeConfigError naming the variable (never its value). MockStripeClient's webhook_signature is now required (no published default) and verified with hmac.compare_digest. Regression test asserts the forged-webhook scenario leaves the balance unchanged. |
||
|---|---|---|
| .. | ||
| test_billing_core.py | ||
| test_stripe_client.py | ||