Skip to content

Commit

Permalink
Rewrite the test
Browse files Browse the repository at this point in the history
Rewrite the test to check for the html component instead of the message displayed.
  • Loading branch information
crisnicandrei committed Dec 9, 2024
1 parent 54e9ebf commit e7d333f
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ describe('NewPledgeComponent', () => {
expect(find('pr-loading-spinner')).toBeTruthy();
});

it('should display the correct amount of storage if the transaction is succesful', async () => {
it('should display the succes message if the transaction is succesful', async () => {
const { find, instance, fixture } = await shallow.render();

instance.isSuccessful = true;
Expand All @@ -208,8 +208,6 @@ describe('NewPledgeComponent', () => {

const displayedMessage = find('.success-message');

expect(displayedMessage.nativeElement.textContent).toContain(
'Success! 5 GB of Permanent storage has been added to your account.',
);
expect(displayedMessage).toBeTruthy();
});
});

0 comments on commit e7d333f

Please sign in to comment.