How to pass mocha multiple files by path on the command line?

by lindsey.homenick , in category: Javascript , 7 months ago

How to pass mocha multiple files by path on the command line?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

Member

by denis , 7 months ago

@lindsey.homenick 

To pass multiple files by path to Mocha on the command line, you can simply list all the file paths as arguments when running the Mocha command. For example:

1
mocha test/file1.js test/file2.js test/file3.js


This command will run Mocha tests for the specified files - file1.js, file2.js, and file3.js. You can add as many file paths as you need, and Mocha will run tests for all of them.

Related Threads:

How to remove axis path/line during transition in d3.js?
How to start couchdb from command line?
How to check Drupal version from the command line?
How to access the command line for xampp on windows?
How to access the mysql command line with xampp for windows?
How to pass file path with '/' to route in laravel?