You are on page 1of 1

Playwright

Introduction:
Playwright is a powerful Node library for browser automation, designed to automate tasks
in web browsers such as Chrome, Firefox, and WebKit. It provides a unified API for cross-
browser automation and supports various browser testing scenarios.

Installation:
To use Playwright, you need to install it as a dependency in your Node.js project. Run the
following command in your project's directory:
Command : “npm install playwright”, run test : “run npx playwright test”

Followed Steps:
Configure Project for Playwright test case in same project.
Written test case for given points which mentioned in jira ticket.
Configure Pipeline on github action for every commit.
Github config steps:

 First I created one more job in tests.yml file


 Then I created a virtual machine with node version 20.
 Then run docker compose up command to run my project in current environment to
access localhost:2424 URL.
 Then I restore my db. dump file (dump has login credentials only)
 Then redirect to my Playwright folder
 Then RUN command like npm install , playwright dependency, and then npm test.
Which execute my playwrite test case.
 Also pushed my docker file changes which you suggested to access denied issue on
docker compose up

And I added few changes in my frontend .ejs and .js file . That was required to run test case.
File name’s ( load-save.20230922.js, analysis.ejs, package.json and common-
functions.20231108.js )

You might also like