0
votes

Tried testing (protractor on angularjs application) with firefox 47 and backfired. Tried downgrading to 46.0.1 after SO'ing around, still nothing. Anybody found a current solution? Looks like the solutions keep changing. Now we need a new one. (tests run with chrome so far)

Here's my error;

C:\this\is\my\folder\for\protractor\tests\e2e>protractor conf.js

[11:02:12] I/direct - Using FirefoxDriver directly...

[11:02:12] I/launcher - Running 1 instances of WebDriver

C:\Users\dev\AppData\Roaming\npm\node_modules\protractor\node_modules\selenium-webdriver\lib\webdriver.js:62

let session = flow.execute(function() {

Error: Could not locate Firefox on the current system

at Error (native)

conf.js

exports.config = {
  seleniumAddress: 'http://localhost:4444/wd/hub',

  capabilities: {
      'browserName': 'firefox'
  },

  directConnect: true,

  framework: 'jasmine2',

  specs: ['specs/*spec.js'],
};
1
did you try re-installing firefox again? - Ram Pasala
I'm using firefox 45... I know there are issues with firefox 47 and protractor, not sure about firefox 46. So I downgraded, maybe try downgrading one more version? - Gunderson
@igniteram1 @Gunderson tried 45 and just 46 now.. nothing working. I'm getting Error: ECONNREFUSED connect ECONNREFUSED 127.0.0.1:4444 - colin_dev256
when you are using the firefox browser, please comment the selenium address. then try it once. - rajana sekhar
@Gunderson downloaded 45.0.1 and it worked. Issue now is navigating from an https secure page with firefox. Security warning popup prevents protractor from continuing gracefully - colin_dev256

1 Answers

0
votes

Protractor cannot locate the Firefox executable on the standard location. To fix this, add the following line:

firefoxPath: 'C:/Programs/Firefox/firefox.exe',

in your 'protractor.config.js' file (after the 'directConnect' property). Of course, the directories names should match these on your machine.

Additional note: if you use portable version of Firefox, try the standard one.