1.0.3 • Published 1 year ago

core-hubplaywright-framework v1.0.3

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

This framework uses Playwright, Cucumber, Node and Typescript as the underlying tech stack

The code is committed to GIT and the repo name is HubPlaywright. The main branch is the prod branch and will always be in a fit to run state. Prior approval is needed before committing anything to the main branch, as this might start failing the CI/CD pipelines.

GIT URL: https://hub24.visualstudio.com/Agility/_git/HubPlaywright

To setup the framework on your local machine, you need to create this folder structure in C: C:/GIT_Automation and then download the repo in HubPlaywright folder inside C:/GIT_Automation

Clone the above repo at C:/GIT_Automation/HubPlaywright

Now open Webstorm and select Open Folder. Install these plugins in Webstorm,

.env Files Support

Batch Scripts Support

Cucumber+

Properties

Open C:/GIT_Automation/HubPlaywright/e2e folder in Webstorm.

Once the project loads in Webstorm, open the terminal within the IDE and run the below commands in order,

npm init npx -p typescript tsc --init npm add playwright -D npm add @playwright/test -D npm add @cucumber/cucumber -D npm add typescript -D npm add ts-node -D npx playwright install npm install dotenv --save npm add cucumber-html-reporter

Once these NPM packages are successfully installed locally, the framework is all set to run.

To run the tests, execute: ./run_tests.bat

This command will execute all the feature files in src/features

All the page files must be placed inside src/step_definitions/assertions and must be named as abc.pages.ts

This ensures that page files are separeted from other files