Skip to content

Commit

Permalink
ADOP-2605 - Nightly Test pipeline fix (#1615)
Browse files Browse the repository at this point in the history
* Sign in navigateTo function added

* Fixed month indexing

---------

Co-authored-by: Abigail Smith <148337562+abigailsmith97@users.noreply.github.com>
  • Loading branch information
AustenStevensMOJ and abigailsmith97 authored Jan 9, 2025
1 parent f66f833 commit a64a54b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions playwright-e2e/helpers/e2eJourneyHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export async function citizenAdoptionSignInWithNoPartner(
userPassword: string,
locator: string
): Promise<void> {
await app.signIn.navigateTo();
await app.signIn.signIn(userEmail, userPassword);
await app.numberOfApplicants.numberOfApplication(locator);
await app.numberOfApplicants.fillNotSpouseOrCivilPartnerDetails('Text to be randomly generated');
Expand All @@ -19,6 +20,7 @@ export async function citizenAdoptionSignInWithPartner(
userPassword: string,
locator: string
): Promise<void> {
await app.signIn.navigateTo();
await app.signIn.signIn(userEmail, userPassword);
await app.numberOfApplicants.numberOfApplication(locator);
await app.basePage.clickSaveAndContinue();
Expand Down
2 changes: 1 addition & 1 deletion playwright-e2e/pages/reviewSubmit.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export default class ReviewSubmit extends BasePage {
await expect(this.cardDetailsH1).toBeVisible();
await expect(this.cost).toBeVisible();
await this.cardNumber.fill('4444333322221111');
await this.expMonth.fill(`${today.getMonth()}`);
await this.expMonth.fill(`${today.getMonth() + 1}`);
await this.expYear.fill(`${today.getFullYear() + 2}`);
await this.cardName.fill(name);
await this.securityCode.fill('123');
Expand Down
1 change: 1 addition & 0 deletions playwright-e2e/tests/smoke.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ test.describe('smoke test', () => {
const appOneName = await app.applicantOneNameCreate();
const childNames = await app.childNameCreate();

await app.signIn.navigateTo();
await app.signIn.signIn(userEmail, userPassword);
await app.numberOfApplicants.numberOfApplication(applicantNumber);
await app.basePage.clickSaveAndContinue();
Expand Down

0 comments on commit a64a54b

Please sign in to comment.