feat(billing): end-to-end Stripe subscription signup with platform enforcement
Move core signup service from marketplace to billing module, add automatic Stripe product/price sync for tiers, create loyalty-specific signup wizard, and enforce that platform is always explicitly known (no silent defaulting to primary/hardcoded ID). Key changes: - New billing SignupService with separated account/store creation steps - Stripe auto-sync on tier create/update (new prices, archive old) - Loyalty signup template (Plan → Account → Store → Payment) - platform_code is now required throughout the signup flow - Pricing/signup pages return 404 if platform not detected - OMS-specific logic (Letzshop claiming) stays in marketplace module - Bootstrap script: scripts/seed/sync_stripe_products.py Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,19 +1,17 @@
|
||||
"""Unit tests for PlatformSignupService."""
|
||||
"""Unit tests for PlatformSignupService (now in billing module)."""
|
||||
|
||||
import pytest
|
||||
|
||||
from app.modules.marketplace.services.platform_signup_service import (
|
||||
PlatformSignupService,
|
||||
)
|
||||
from app.modules.billing.services.signup_service import SignupService
|
||||
|
||||
|
||||
@pytest.mark.unit
|
||||
@pytest.mark.marketplace
|
||||
class TestPlatformSignupService:
|
||||
"""Test suite for PlatformSignupService."""
|
||||
"""Test suite for SignupService (moved from marketplace to billing)."""
|
||||
|
||||
def setup_method(self):
|
||||
self.service = PlatformSignupService()
|
||||
self.service = SignupService()
|
||||
|
||||
def test_service_instantiation(self):
|
||||
"""Service can be instantiated."""
|
||||
|
||||
Reference in New Issue
Block a user