
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
Look ma', without .json files:
var argv = require('minimist')(process.argv.slice(2)),
nwrun = require('nwrun');
nwrun({
argv: argv,
force: argv.force,
target: argv.target,
standalone: argv.standalone,
src_folders: process.cwd() + '/tests',
output_folder: process.cwd() + '/reports'
}, function(success) {
if (!success) {
process.exit(1);
}
});
This is just a dirty-hack based on nightwatch.initGrunt() method due compatibility issues with grunt-nightwatch itself.
Unlike other solutions we are not spawning the nightwatch process, instead, we fake its settings in runtime.
Another interesting feature is the downloading of the selenium-server-standalone*.jar file.
Is like running nightwatch but programmatically.
Since
nwrun@0.2.0thenightwatchis no longer a sub-dependency and you must install it.
If you're installing
nightwatchglobally ensure you runnpm link nightwatchwithin your project to make it work locally.
nwrun(options, callback)
Options
argv — main argvs for the nightwatch instanceforce — always force the download of the selenium jartarget — shortcut for specifying environments ( --env a,b)standalone — if true will start selenium (will be downloaded if missing)jar_url — custom endpoint for the downloading the selenium jarjar_path — custom directory for saving the selenium jar locallyjar_version — custom version for the given jar_url, e.g. 2.45.0config_path — custom path for JSON settings and options, it can be overriden per targetWhen done callback(success) will get executed.
If success is false means something failed.
Otherwise you're done.
All other options are passed directly to the
nightwatch.runner()method.
FAQs
Hacky runner for Nightwatch CLI
We found that nwrun demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.