GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - browserstack/browserstack-nightwatch-load-testing-sample: A sample repository demonstrating load testing with the Nightwatch framework

BranchesTags
Open more actions menu

Latest commit

 

History

21 Commits
21 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
tests
tests
 
 
.gitignore
.gitignore
 
 
.npmrc
.npmrc
 
 
CODEOWNERS
CODEOWNERS
 
 
README.md
README.md
 
 
browserstack-load.yml
browserstack-load.yml
 
 
nightwatch.conf.js
nightwatch.conf.js
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 

Repository files navigation

browserstack-nightwatch-load-testing-sample

This repo contains samples for running Nightwatch tests on BrowserStack Load Testing using the BrowserStack CLI.

BrowserStack Logo

Setup

  • Clone the repo git clone https://github.com/browserstack/browserstack-nightwatch-load-testing-sample.git.
  • Set your credentials as environment variables, as described in Set your credentials.
  • Use Node.js 20 or later. For the seven-day release-age policy in .npmrc, also use npm 11.10 or later (npm install -g [email protected], which needs Node.js 20.17+ or 22.9+); older npm ignores that policy.
  • Run npm i to install the dependencies.
  • Open the browserstack-load.yml file and update it with the relevant load test configurations.

Set your credentials

The BrowserStack CLI reads your credentials from environment variables. Copy your username and access key from Account Settings and export them in the shell you run the test from:

On macOS or Linux (bash or zsh), run the lines below. The second one prompts for the key without echoing it, so the key stays out of your shell history:

export BROWSERSTACK_USERNAME="<your-username>"
printf 'BrowserStack access key: '; read -rs BROWSERSTACK_ACCESS_KEY; echo; export BROWSERSTACK_ACCESS_KEY

On Windows, run these in PowerShell. The second line prompts for the key in the same way:

$env:BROWSERSTACK_USERNAME = "<your-username>"
$env:BROWSERSTACK_ACCESS_KEY = [System.Net.NetworkCredential]::new('', (Read-Host -AsSecureString 'BrowserStack access key')).Password

These variables last only for the current terminal session. If the CLI reports an authentication error, check that both are set in the terminal you run it from.

Never commit your credentials. Keep your access key out of browserstack-load.yml and every other file you push. If a key is ever exposed, regenerate it from Account Settings.

Running your tests

  • Download the BrowserStack CLI for your operating system. The download is a zip: extract it and place the browserstack-cli binary (browserstack-cli.exe on Windows) in the root of this project. On macOS or Linux, also run chmod +x browserstack-cli, since some unzip tools drop the executable bit.
    • macOS x86
    • macOS ARM
    • Windows x86
    • Linux x86
    • Linux ARM
  • Start your test:
    • macOS / Linux: ./browserstack-cli load run
    • Windows (PowerShell): .\browserstack-cli.exe load run

Notes

  • You can view your test results on the BrowserStack Load Testing dashboard

About

A sample repository demonstrating load testing with the Nightwatch framework

Resources

Readme
Activity
Custom properties

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.