Skip to content
Nightwatch.js custom commands and assertions
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs Added command to wait until page is fully loaded. Jul 11, 2017
es6 forgot a file Mar 29, 2018
js forgot a file Mar 29, 2018
tests missing parameter in testing elementHasChildrenCount Mar 14, 2018
.gitignore added tests with nightwatch and mockserver Feb 4, 2015
.jshintrc
.travis.yml use node 7 in tests Mar 14, 2018
Contributing.md converted all commands from coffee to es6, then converted to es5 with… Aug 2, 2016
LICENSE Initial commit Dec 4, 2014
Readme.md
gulpfile.js flatten output of new version of markdox (thanks gulp-flatten) Jun 21, 2017
package.json updated package.json version Apr 5, 2018
runTests.sh fix: avoid killing all java processes + trap ctrl+c and kill mockserv… Jun 28, 2017
yarn.lock

Readme.md

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

You can’t perform that action at this time.