-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update the business details section in tombstone (#64)
* update the business details section in tombstone * add cypress tests
- Loading branch information
1 parent
b204a60
commit 27d1f1a
Showing
5 changed files
with
135 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
context('Business tombstone - business detail section', () => { | ||
it('Verify the business detail section is rendered for SP/GP businesses', () => { | ||
cy.visitBusinessDashFor('businessInfo/sp/active.json') | ||
|
||
cy.get('[data-cy="business-details"]') | ||
.should('contain', 'Registration Date') | ||
.should('contain', 'Registration Number') | ||
.should('contain', 'Business Number') | ||
.should('not.contain', 'Incorporation Number') | ||
.should('contain', 'Email') | ||
.should('contain', 'Phone') | ||
}) | ||
|
||
it('Verify the business detail section is rendered for non-firm (SP/GP) businesses', () => { | ||
cy.visitBusinessDashFor('businessInfo/ben/active.json') | ||
|
||
cy.get('[data-cy="business-details"]') | ||
.should('not.contain', 'Registration Date') | ||
.should('not.contain', 'Registration Number') | ||
.should('contain', 'Business Number') | ||
.should('contain', 'Incorporation Number') | ||
.should('contain', 'Email') | ||
.should('contain', 'Phone') | ||
}) | ||
|
||
it('Verify the change buttons for email and phone number', () => { | ||
// Intercept the request for the business profile page | ||
cy.intercept('GET', '**businessprofile**').as('goToBusinessProfilePage') | ||
|
||
cy.visitBusinessDashFor('businessInfo/ben/active.json') | ||
.get('[data-cy="business-details"]') | ||
.get('[data-cy="value-email"]').trigger('mouseover') | ||
.get('[data-cy="change-button-email"]').click() | ||
.wait('@goToBusinessProfilePage') | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters