8

I currently have nightwatch.js setup using the vue automated setup. That template is located here.

https://github.com/vuejs-templates/webpack/tree/master/template/test/e2e

Is it possible to run nightwatch assertions through the command line in a REPL like fashion that is available in webdriver.io? Here is a reference to the webdriver feature https://twitter.com/webdriverio/status/806911722682544128


Update, we have moved to using Cypress.io It has made us pretty happy

Austio
  • 5,448
  • 17
  • 32
  • i actually went with testcafe.js as nightwatch.js unfortunately does not come close to what i expect from an e2e testing tool... – phoet Jun 18 '17 at 19:10
  • @phoet we moved to webdriver.io Still haven't found anything in the JS world that is up to same level as rails. – Austio Jun 19 '17 at 01:57
  • tried webdriver as well, found testcafe to be especially nice to integrate. worked more or less out of the box. – phoet Jun 20 '17 at 12:26

1 Answers1

0

You can use nightwatch-repl package available on NPM.

https://www.npmjs.com/package/nightwatch-repl

// nightwatch.conf.js

var repl = require('nightwatch-repl');

module.exports = (function (settings) {
    repl.init(settings);
    ...
    ...
    return settings;
})(require('./nightwatch.json'));

Once you run your tests and invoke browser.repl()

you should see the following in your console

Running:  Login to dashboard

Type in a command (eg: browser.function()) or type "quit" to exit
repl>
Yohann
  • 136
  • 2
  • 13