npm nightwatch 1.3.0
v1.3.0

latest releases: 3.6.0, 3.5.0, 3.4.1...
4 years ago

New features

BDD describe Interface

Added BDD describe interface for writing tests. No further configuration is necessary and both exports and bdd interfaces can be mixed together (though not in the same file).
More details

assert.not Assertions

You can use .not assertions for every existing and custom assertion. Custom assertions will require to be updated to the new interface in order to make use of .not. Refer to the Custom assertions docs for details.

module.exports = {
  demoTest(browser) {
    browser
      .assert.not.elementPresent('.not_present') // previously .assert.elementNotPresent()
      .assert.not.visible('.non_visible'); // previously .assert.hidden()
      .assert.not.urlContains('http://');

    // ...
  }
}

New APIs

Commands:

Assertions:

Expect:

Improvements

New CLI options:

  • --headless - Launch the browser (Chrome or Firefox) in headless mode.
  • --timeout - Set the global timeout for assertion retries before an assertion fails. The various timeout values are defined in the Globals section.

More details

nightwatch Test Runner

  • Auto-generated configuration: if no existing config file is found in the current folder, Nightwatch will generate a nightwatch.conf.js config file, based on the operation system and existing driver packages. More details
  • Added support for http keepAlive which should be enabled when using remote testing services. See Configuration for details.
  • Added several improvements for running tests against cloud testing provider Browserstack; see also an example configuration for using Browserstack.

Fixes

  • Fixed #2219 - an issue with locating elements from page object sections using non @-based element identifiers
  • Fixed getElementSize and getLocation commands for w3c webdriver clients - #fd10c9b

Don't miss a new nightwatch release

NewReleases is sending notifications on new releases.