Skip to content

Commit

Permalink
PP-12444 cypress test confirm org details stripe setup task
Browse files Browse the repository at this point in the history
  • Loading branch information
nlsteers committed Dec 6, 2024
1 parent 0165b53 commit c63624d
Show file tree
Hide file tree
Showing 8 changed files with 339 additions and 32 deletions.
2 changes: 1 addition & 1 deletion app/services/stripe-details.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ const updateStripeDetailsUploadEntityDocument = async (service, account, file) =
}

/**
* Updates Stripe account director for the given service and account type
* Updates Stripe account organisation name and address for the given service and account type
* @param {GatewayAccount} account
* @param {GOVUKPayService} service
* @param {StripeOrganisationDetailsParams} newOrgDetails
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ describe('Stripe details settings', () => {
describe('Completed', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE,
bankAccount: true
Expand All @@ -89,7 +89,7 @@ describe('Stripe details settings', () => {
describe('Not yet started', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
})
Expand Down Expand Up @@ -119,7 +119,7 @@ describe('Stripe details settings', () => {
describe('When inputting bank details', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
})
Expand Down Expand Up @@ -192,7 +192,7 @@ describe('Stripe details settings', () => {
describe('When submitting valid bank details', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
}),
Expand All @@ -210,7 +210,7 @@ describe('Stripe details settings', () => {
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
}),
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE,
bankAccount: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ describe('Stripe details settings', () => {
describe('Completed', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE,
companyNumber: true
Expand All @@ -89,7 +89,7 @@ describe('Stripe details settings', () => {
describe('Not yet started', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
})
Expand Down Expand Up @@ -119,7 +119,7 @@ describe('Stripe details settings', () => {
describe('When inputting a company registration number', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
})
Expand Down Expand Up @@ -158,7 +158,7 @@ describe('Stripe details settings', () => {
describe('When selecting yes and submitting a company number', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
}),
Expand All @@ -176,7 +176,7 @@ describe('Stripe details settings', () => {
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
}),
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE,
companyNumber: true
Expand Down Expand Up @@ -206,7 +206,7 @@ describe('Stripe details settings', () => {
describe('When selecting no and completing the task', () => {
beforeEach(() => {
setStubs({}, [
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
}),
Expand All @@ -221,7 +221,7 @@ describe('Stripe details settings', () => {
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE
}),
stripeAccountSetupStubs.getServiceAndAccountTypeStripeSetupSuccess({
stripeAccountSetupStubs.getStripeSetupProgressByServiceExternalIdAndAccountType({
serviceExternalId: SERVICE_EXTERNAL_ID,
accountType: LIVE_ACCOUNT_TYPE,
companyNumber: true
Expand Down
Loading

0 comments on commit c63624d

Please sign in to comment.