diff --git a/apps/billing-web/e2e/invoices.spec.ts b/apps/billing-web/e2e/invoices.spec.ts
index c661c33cec1..5883e7d987e 100644
--- a/apps/billing-web/e2e/invoices.spec.ts
+++ b/apps/billing-web/e2e/invoices.spec.ts
@@ -20,5 +20,14 @@ test('opens the provider portal for invoices, returning to this page', async ({
const portal = cloud.requests.find(
(request) => request.path === '/billing/payment-portal'
)
- expect(portal?.body).toStrictEqual({ return_url: `${E2E_ORIGIN}${invoices}` })
+ const portalReturn = entryPath('invoices', { portal: 'return' })
+ expect(portal?.body).toStrictEqual({
+ return_url: `${E2E_ORIGIN}${portalReturn}`
+ })
+
+ await page.goto(portalReturn)
+ await page.waitForURL(`${E2E_ORIGIN}${invoices}`)
+ await expect(
+ page.getByRole('button', { name: 'Open invoices' })
+ ).toBeVisible()
})
diff --git a/apps/billing-web/src/components/PaymentMethodsPanel.vue b/apps/billing-web/src/components/PaymentMethodsPanel.vue
index d8e3230ad97..6581c93ec0d 100644
--- a/apps/billing-web/src/components/PaymentMethodsPanel.vue
+++ b/apps/billing-web/src/components/PaymentMethodsPanel.vue
@@ -1,34 +1,26 @@
@@ -41,7 +30,7 @@ async function openPortal() {
{{ t('hosted.invoices.body') }}
- {{ failure }}
+ {{ refusal(failure) }}