A library that packages common boilerplate Playwright code necessary for all neeto products.
First, navigate to the Playwright test directory:
cd playwright-tests
Then, install the package using Yarn:
yarn add "@bigbinary/neeto-playwright-commons@latest"
If neeto-playwright-commons
is already listed in package.json
of Playwright project, simply install dependencies with:
yarn install
neeto-playwright-commons has some peer dependencies which can be installed using the commands listed below:
A collection of common utility functions used across all our neeto products. Try out the utility functions live at neetoCommons REPL.
yarn add @bigbinary/neeto-cist
Faker is used to generate fake data.
yarn add @faker-js/faker
yarn add @playwright/test
Run linters against staged git files.
yarn add lint-staged
dotenv-webpack
is a secure webpack plugin that supports
dotenv and other environment variables.
yarn add dotenv-webpack
Dayjs is a JavaScript library that parses, validates, manipulates, and displays dates and times.
yarn add dayjs
Ramda is a JavaScript library that facilitates functional programming in JavaScript. It provides a collection of utility functions that operate on data.
yarn add ramda
Use your i18next
translations in Playwright to create multi-language
selectors.
yarn add playwright-i18next-fixture
We can install all the above peer dependencies by running a single command.
yarn add @bigbinary/neeto-cist @faker-js/faker @playwright/test lint-staged dotenv-webpack dayjs ramda playwright-i18next-fixture
Note: ENV variables NEETO_AUTOMATION_FASTMAIL_API_KEY
and
FASTMAIL_DOMAIN_NAME
are required for this methods to work.
Note: Either ENV variables SLACK_WORKSPACE
, SLACK_LOGIN_PASSWORD
and
SLACK_LOGIN_EMAIL
is required for this method to work or custom credentials
workspace
, loginPassword
and loginEmail
must be passed.
Note: ENV variables NEETO_AUTOMATION_FASTMAIL_API_KEY
, FASTMAIL_DOMAIN_NAME
, ZAPIER_LOGIN_EMAIL
, ZAPIER_LOGIN_PASSWORD
, and ZAP_ID
are required for this methods to work.
You can import the utility functions and constants from the
@bigbinary/neeto-playwright-commons
wherever required.
import { COMMON_SELECTORS } from "@bigbinary/neeto-playwright-common";