From e1735447c5157f4bae4021b8febacc0a9fba2acc Mon Sep 17 00:00:00 2001 From: najeeb1023 Date: Sun, 16 Jun 2024 17:00:02 +0200 Subject: [PATCH 1/2] Rebased. --- package.json | 2 +- playwright.config.ts | 2 +- src/test/features/MenSection.feature | 17 ++++++++++++ src/test/pages/MenSection.ts | 38 ++++++++++++++++++++++++++ src/test/resources/menSectionPage.json | 19 +++++++++++++ src/test/steps/menSection.ts | 17 ++++++++++++ 6 files changed, 93 insertions(+), 2 deletions(-) create mode 100644 src/test/features/MenSection.feature create mode 100644 src/test/pages/MenSection.ts create mode 100644 src/test/resources/menSectionPage.json create mode 100644 src/test/steps/menSection.ts diff --git a/package.json b/package.json index 0bd021d..6244e14 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "version": "1.0.0", "main": "index.js", "scripts": { - "lunaapp": "cucumber-js --config=config/cucumber.js" + "lunaapp": "cucumber-js --config=config/cucumber.js --tags @MenSection" }, "keywords": [], "author": "", diff --git a/playwright.config.ts b/playwright.config.ts index 91cdf4c..2b4b15d 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -2,7 +2,7 @@ import { LaunchOptions } from "@playwright/test"; export const config: LaunchOptions = { timeout: 600000, - headless: true, + headless: false, args:['--start-maximized'], slowMo: 300 diff --git a/src/test/features/MenSection.feature b/src/test/features/MenSection.feature new file mode 100644 index 0000000..9a09df2 --- /dev/null +++ b/src/test/features/MenSection.feature @@ -0,0 +1,17 @@ +@MenSection + +Feature: Verify that the user is able to login into an already registered account. + + User enters their details to login. + + Background: User is landed on the webpage. + Given The user lands at the webpage. + + Scenario: User shops for Men Jackets. + When The user clicks on the "". + And The user clicks on "