Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement a centralized payment method definition system #10400

Open
brettshumaker opened this issue Feb 18, 2025 · 0 comments
Open

Implement a centralized payment method definition system #10400

brettshumaker opened this issue Feb 18, 2025 · 0 comments

Comments

@brettshumaker
Copy link
Contributor

Description

Implement a centralized payment method definition system to reduce the complexity of adding and maintaining payment methods in WooCommerce Payments. This will consolidate payment method configurations into a single source of truth, making it easier to add new payment methods and maintain existing ones.

Acceptance criteria

  • Implement the PaymentMethodDefinitionRegistry as the central system for managing payment method definitions
  • Convert all BNPL payment methods to use the new definition system (issues will be created for each remaining payment method)
  • Add comprehensive test coverage
  • Ensure backwards compatibility is maintained during the transition

Testing instructions

  1. Enable each BNPL payment method in WP Admin and verify:
    • Payment method appears correctly
    • Icons display properly
    • Country/currency restrictions work as expected
    • Payment flows complete successfully
  2. Change store currency and country to verify payment method availability rules

Dev notes

  • All payment method definitions should follow PSR-4 naming conventions
  • Icon generation is part of the build process

Additional context

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants