Merge pull request #23203 from overleaf/ii-flexible-group-licensing-no-billing-details

[web] FL handle subscriptions with missing billing info

GitOrigin-RevId: 34209299c039992a80da5739e086beb5d0ede7b0
This commit is contained in:
ilkin-overleaf
2025-02-05 09:05:50 +00:00
committed by Copybot
parent 72be034435
commit 16130b79db
14 changed files with 242 additions and 2 deletions
@@ -0,0 +1,35 @@
import '../../../helpers/bootstrap-5'
import { SplitTestProvider } from '@/shared/context/split-test-context'
import MissingBillingInformation from '@/features/group-management/components/missing-billing-information'
describe('<MissingBillingInformation />', function () {
beforeEach(function () {
cy.window().then(win => {
win.metaAttributesCache.set('ol-groupName', 'My Awesome Team')
})
cy.mount(
<SplitTestProvider>
<MissingBillingInformation />
</SplitTestProvider>
)
})
it('shows missing payment details notification', function () {
cy.findByRole('alert').within(() => {
cy.findByText(/missing payment details/i)
cy.findByText(
/it looks like your payment details are missing\. Please.*, or.*with our Support team for more help/i
).within(() => {
cy.findByRole('link', {
name: /update your billing information/i,
}).should('have.attr', 'href', '/user/subscription')
cy.findByRole('link', { name: /get in touch/i }).should(
'have.attr',
'href',
'/contact'
)
})
})
})
})