'Issue while running the js file on nightwatch

I am running Nightwatch through Vs code. Where inside the src folder test I have 2 js files one is a customer.js and the second is supplier.js. Now I want to run only customer.js using command npx nightwatch -e chrome

How can I run single js file

I am running Nightwatch through Vs code. Where inside the src folder test I have 2 js files one is a customer.js and the second is supplier.js. Now I want to run only customer.js using command npx nightwatch -e chrome

How can I run single js file



Solution 1:[1]

Would this work?

npx nightwatch [filepath]

Replace [filepath] with the filepath of your JS file from the current folder. Something like:

node_modules/nightwatch/examples.tests/jsfilename.js 

So that:

npx nightwatch node_modules/nightwatch/examples.tests/customer.js

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Jeremy Caney