Skip to content

Commit

Permalink
Merge pull request #1338 from thebiggive/remove-erroring-test
Browse files Browse the repository at this point in the history
Remove erroring test: Doantion Start Form Should allow paying with do…
  • Loading branch information
bdsl authored Oct 6, 2023
2 parents 0801e86 + 0fed4e8 commit b6ae094
Showing 1 changed file with 0 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -462,28 +462,6 @@ describe('DonationStartNewPrimaryComponent', () => {
expect(component.donationForm.controls.marketing!.get('optInTbgEmail')?.errors).toBeNull();
});


it('Should allow paying with donation funds with no saved payment method', async () => {
var finaliseCashBalancePurchaseCalled = false;

const fakeDonationService = {
getDefaultCounty: () => 'GB',
finaliseCashBalancePurchase: (donation: Donation)=> {
finaliseCashBalancePurchaseCalled = true;
return of(donation);
},
getPaymentMethods: () => of({data: []}),
} as unknown as DonationService;

const sut = makeDonationStartFormComponent(fakeDonationService);

sut.loadPerson({cash_balance: {gbp: 100}}, 'personID', 'jwt');

await sut.payWithStripe();

expect(finaliseCashBalancePurchaseCalled).toBe(true)
});

it('Should not allow paying with with no payment method and no funds', async () => {
var finaliseCashBalancePurchaseCalled = false;

Expand Down

0 comments on commit b6ae094

Please sign in to comment.