How can I use a parameter to a protractor configuration file to chose steps?

Following the lead of this question, I tried (naievely) to do this:

protractor test/features/protractor-conf.js --params.test_set=dev_test



exports.config = {
   // ...
  specs: [browser.params.test_set+'/*.feature'],

... but of course it doesn't work because browser is not defined at the time that the conf file is parse.

So how could I achieve this effect: passing a parameter to protractor that determines the specs?



Use the --specs command-line argument:

--specs Comma-separated list of files to test

protractor test/features/protractor-conf.js --specs=dev_test/*.feature

Note that dev_test/*.feature would be passed into the protractor's command-line-interface which would resolve the paths based on the current working directory (source code).


Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.