![require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages](https://cdn.sanity.io/images/cgdhsj6q/production/be8ab80c8efa5907bc341c6fefe9aa20d239d890-1600x1097.png?w=400&fit=max&auto=format)
Security News
require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
@empiricalrun/playwright-utils
Advanced tools
Playwright utils for test code repos of our customers
locator.query
APIThis dynamically generates a random email address that can be used for the test (e.g. invite a new user).
import { EmailClient } from "@empiricalrun/playwright-utils";
const client = new EmailClient();
const address = client.getAddress();
// Input the `address` in the application
// that sends the email.
// Get email received on the `address`
const email = await client.waitForEmail();
This uses a known (static) email that can be used to login into an application.
This needs an email id (e.g. test-login-user
). The email id
is appended with the domain (managed internally) to get the full
email address.
import { EmailClient } from "@empiricalrun/playwright-utils";
const emailId = `test-login-user`;
const client = new EmailClient({ emailId });
const address = client.getAddress(); // Returns full address with domain
// Get email received on the `address`
const email = await client.waitForEmail();
// Get login OTP
const loginCode = email.codes[0];
To use the custom HTML reporter, add the following to your Playwright config:
import { defineConfig } from "@playwright/test";
import { baseConfig } from "@empiricalrun/playwright-utils";
export default defineConfig({
...baseConfig,
...
});
FAQs
Playwright utils for test code repos of our customers
The npm package @empiricalrun/playwright-utils receives a total of 1,790 weekly downloads. As such, @empiricalrun/playwright-utils popularity was classified as popular.
We found that @empiricalrun/playwright-utils demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.