2016-07-21 33 views
0

從持續集成的角度來看,我更願意使用本地安裝而不是全局文檔作爲當前文檔的狀態。我搜索了一會兒,看了一下「ember test --help」的api,我看不到明確指出phantomjs位置的能力--earer希望它能在全球範圍內使用。使用本地安裝的phantomjs進行「餘燼測試」

是否有可能運行類似「ember test --phantomjs node_modules \ phantomjs \ bin \ phantomjs」?或者修改testem.js來聲明phantomjs的位置?

回答

2

您可以加入到路徑它們在package.json

所以因此你的package.json有

"scripts": { 
    "start": "ember server", 
    "build": "ember build", 
    "test": "ember test", 

npm test將運行ember test但裏面的腳本部分命令這種情況下node_modules/.bin運行與npm test測試對於該運行,它會將node_modules/.bin添加到PATH中。所以你可以保留幻影在當地的依賴

相關問題