How to configure Protractor to use Cucumber

后端 未结 4 1584
别那么骄傲
别那么骄傲 2021-02-20 03:30

As of 0.20.1 Cucumber is now fully supported in Protractor but I\'m battling to find any documentation on how to configure it properly. Any idea how you would setup world.js?

4条回答
  •  北恋
    北恋 (楼主)
    2021-02-20 04:27

    Add it as a framework in the configuration file:

    exports.config = {
      // set to "custom" instead of cucumber.
      framework: 'custom',
    
      // path relative to the current config file
      frameworkPath: 'protractor-cucumber-framework'
    
      // relevant cucumber command line options
      cucumberOpts: {
        format: "summary"
      }
    };
    

    More information here: Protractor Frameworks

提交回复
热议问题