Skip to content

e2e operate: report gateway exceptions as a failed operation - #82

Merged
loevgaard merged 1 commit into
2.xfrom
chore/e2e-operate-catch-gateway-exceptions
Aug 17, 2026
Merged

loevgaard merged 1 commit into
2.xfrom
chore/e2e-operate-catch-gateway-exceptions

Conversation

@loevgaard

Copy link
Copy Markdown
Member

Harness only (examples/e2e/operate.php, outside the phpstan/ecs paths — checked with php -l).

operate.php caught only QuickpayException (the API refusing a request), so a Payum-side exception surfaced as an uncaught fatal with a stack trace. Seen live during the #73 check: OperationRejectedException from #72 — Quickpay processed the capture up front and the acquirer declined it. It now reports those like an API failure, naming the class:

capture   ... FAILED: OperationRejectedException: Quickpay declined the capture of payment 612102024: status 40000 (Rejected test operation).

Also covers OperationPendingException (#80), "nothing left to refund" and a missing quickpayPaymentId.

operate.php caught only QuickpayException (the API refusing a request),
so a Payum-side exception surfaced as an uncaught fatal with a stack
trace. Seen live during the #73 check: OperationRejectedException from
#72 — Quickpay processed the capture and the acquirer declined it. It
now reports those the same way, naming the exception class:

  capture   ... FAILED: OperationRejectedException: Quickpay declined the capture of payment …

Refs #71.
@codecov

codecov Bot commented Aug 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.40%. Comparing base (fbfaa0a) to head (f6d9034).

Additional details and impacted files
@@            Coverage Diff            @@
##                2.x      #82   +/-   ##
=========================================
  Coverage     98.40%   98.40%           
  Complexity      199      199           
=========================================
  Files            19       19           
  Lines           501      501           
=========================================
  Hits            493      493           
  Misses            8        8           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@loevgaard
loevgaard merged commit 87661d9 into 2.x Aug 17, 2026
21 checks passed
@loevgaard
loevgaard deleted the chore/e2e-operate-catch-gateway-exceptions branch August 17, 2026 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant