0
我正在使用量角器實施黃瓜,一切似乎都沒問題,因爲沒有失敗,但是當我執行termal時表示執行了0場景。量角器沒有運行黃瓜的功能文件
這是我conf.js:
exports.config = {
seleniumAddress: 'http://127.0.0.1:4444/wd/hub',
framework: 'custom',
frameworkPath: require.resolve('protractor-cucumber-framework'),
capabilities: {
'browserName': 'firefox'
},
specs: './features/login.feature',
onPrepare: function(){
browser.driver.manage().window().maximize()
browser.get('http:www.google.com')
},
jasmineNodeOpts: {
showColors: true, // Use colors in the command line report.
},
cucumberOpts: {
require: 'features/steps/my_steps.js',
}
};
這是我的框架的樹:
但是當我執行protractor conf.js
我有這樣的輸出端子:
[17:27:45] I/launcher - Running 1 instances of WebDriver
[17:27:45] I/hosted - Using the selenium server at http://127.0.0.1:4444/wd/hub
0 scenarios
0 steps
0m00.000s
所以我只想知道如果我conf.js有問題,或者我應該執行另一個命令來使用量角器運行功能文件。
希望你能幫助我。
所以你的意思是我的規格路徑是錯誤的?因爲我嘗試與differents路徑實際上,如果我添加一個路徑的測試只是使用量角器工作是執行測試,但是當我添加指向黃瓜功能的路徑不會執行任何操作。 – burq24
@ burq24,看[this](https://github.com/angular/protractor/blob/master/lib/config.ts#L192)。 你也可以舉一個功能文件的例子嗎? – wswebcreation
當然這是我對功能'特點:用量角器 方案中運行黃瓜:量角器和黃瓜測試 的。說Hi' – burq24