Skip to content

nightwatchjs/nightwatch-vscode

Repository files navigation

Overview

The Nightwatch Extension for Visual Studio Code is a powerful tool that enables developers to write, run, and view test results in a single, integrated environment. With an easy installation process, user-friendly interface, and powerful features, this extension is the ideal solution for developers looking to streamline their testing workflow.

Key Features

  • Easy Installation: Nightwatch, the local Selenium server, and browser drivers are automatically installed, making the setup process a breeze.
  • Run and Debug your tests: You can run single or multiple tests with an easy-to-use user interface that displays tests in a simple format.
  • View tests results: Viewing test output is simple with the ability to view individual and aggregate test results, as well as the output of the test execution in the VS Code terminal.
  • Quick Setting Panel: The quick settings panel gives you more control over test runs, such as running in headless mode, opening the report post-test runs, and controlling the number of parallels for your Nightwatch test runs.
  • Environments Panel: The environments panel provides a quick way to select the environment (browsers) to run your tests.

Screenshot 2022-09-16 at 1 18 43 PM

Requirements

This extension requires Nightwatch JS version v2.3.4 or higher.

Installation

To install the Nightwatch Test Explorer extension, follow these steps:

  1. Open VS Code.
  2. Press Ctrl+Shift+X or Cmd+Shift+X to open the Extensions panel.
  3. Type nightwatch into the search bar.
  4. Click on the Nightwatch Test Explorer extension.
  5. Click the Install button.

Alternatively, you can download the extension from the Visual Studio Code Marketplace.

Usage

To use the Nightwatch Test Explorer extension, follow these steps:

  1. Open a project that uses Nightwatch.
  2. Open the Test Explorer by clicking on the Test View icon in the sidebar.
  3. Run or debug a test by clicking the Play or Debug buttons next to the test.
  4. View test results in the Test Explorer or the VS Code terminal.

Easy Installation

Installing Nightwatch with the Nightwatch Extension is simple and straightforward. It takes care of all the setup and configuration for you, so you can focus on writing and running tests.

installation

Run and Debug your tests

Running and debugging tests is a breeze with the Nightwatch Extension. The user interface is intuitive and easy to use, and the powerful debugging features help you catch and fix issues quickly.

Running test gif

Debug test gif

View tests results

Viewing test results is simple and efficient with the Nightwatch Extension. You can quickly view individual test results, aggregate test results, and output from test execution, all in one place.

View test results gif

Quick Setting Panel

The Quick Settings Panel gives you greater control over your test runs. You can run tests in headless mode, open reports post-test runs, and control the number of parallels for your Nightwatch test runs.

Quick Setting Panel image

Environments Panel

The Environments Panel makes it easy to test across multiple browsers and devices. You can quickly select the environment (browser) you want to run your tests in, and the Nightwatch Extension takes care of the rest. Learn more about Nightwatch environments.

Environment Panel image

Development of the Plugin

When working on the plugin you will need to do the following:

  • Fork this repository
  • Checkout the fork
  • create a branch to fix the issue e.g. git checkout -b issueSomeNumber
  • Install dependencies **npm install . ** npm install -g @vscode/vsce

Go fix the issue and then use on of the npm commands to package and test. See commands available in the package.json

To create an installable extension run the following command from the top level of the repository.

vsce package

About

Run Nightwatch tests in Visual Studio Code

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •