1. nightwatch-custom-commands-assertions
These are some commands and assertion I use when I'm testing with nightwatch.js and selenium.
nightwatch-custom-commands-assertions
Package: nightwatch-custom-commands-assertions
Created by: maxgalbu
Last modified: Tue, 21 Jun 2022 09:31:51 GMT
Version: 1.1.1
License: MIT
Downloads: 9,351
Repository: https://github.com/maxgalbu/nightwatch-custom-commands-assertions

Install

npm install nightwatch-custom-commands-assertions
yarn add nightwatch-custom-commands-assertions

Nightwatch custom commands and assertions

Build Status npm version

These are some commands and assertion I use when I'm testing with nightwatch.js and selenium.

How to use these things?

You can install it using npm:

npm install nightwatch-custom-commands-assertions --save-dev

Then, open the nightwatch.json file in your editor (or create it if it doesn't exist) and edit the custom_commands_path and custom_assertions_path keys so they look like this:

 {
	... //your config
	
	"custom_commands_path" : "node_modules/nightwatch-custom-commands-assertions/js/commands",
	"custom_assertions_path" : "node_modules/nightwatch-custom-commands-assertions/js/assertions",
	
	... //your config again
}

Now you should be able to use these commands/assertions when you call nightwatch --test.

Alternative ways of installing

  • Go into your tests folder (or where your nightwatch.json is) and do:

    git clone https://github.com/maxgalbu/nightwatch-custom-commands-assertions.git
    
  • Download the zipped repository here and extract it wherever you want

You then need to open your nightwatch.json and edit custom_commands_path and custom_assertions_path according to where you cloned or extracted the repository.

Contributing

See Contributing.md.

List of commands

See the docs folder

Dependencies

RELATED POST

10 Must-Know Windows Shortcuts That Will Save You Time

10 Must-Know Windows Shortcuts That Will Save You Time

Arrays vs Linked Lists: Which is Better for Memory Management in Data Structures?

Arrays vs Linked Lists: Which is Better for Memory Management in Data Structures?

Navigating AWS Networking: Essential Hacks for Smooth Operation

Navigating AWS Networking: Essential Hacks for Smooth Operation

Achieving Stunning Visuals with Unity's Global Illumination

Achieving Stunning Visuals with Unity's Global Illumination

Nim's Hidden Gems: Lesser-known Features for Writing Efficient Code

Nim's Hidden Gems: Lesser-known Features for Writing Efficient Code