Protractor fails to run
I have downloaded the angular-seed project and am trying to run the tests. I have not yet made any edits to the code, apart from adding this to protractor-conf.js:
// The address of a running selenium server.
seleniumAddress: 'http://localhost:4444/wd/hub',
When I execute npm run protractor, i see this error:
Using the selenium server at http://localhost:4444/wd/hub
Cannot read property 'matcherFn_' of undefined
[launcher] Runner Process Exited With Error Code: 1
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nod
ejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "protractor"
npm ERR! cwd C:\nginx-1.7.1\html\angular-seed.git\trunk
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.9
npm ERR! code ELIFECYCLE
I think the relevant clue here is matcherFn_, but I can't find anything when looking for it.
> npm ls
├─┬ [email protected]
│ ├── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ ├─┬ [email protected]
│ │ │ ├── [email protected]
│ │ │ └── [email protected]
│ │ └── [email protected]
│ ├─┬ [email protected]
│ │ └── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ └── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ └── [email protected]
├── [email protected]
└── [email protected]
How can I get past the "matcherFn_ of undefined" error?
Try
"devDependencies": {
"karma": "~0.10",
"protractor": "~0.24.1",
"http-server": "^0.6.1",
"bower": "^1.3.1",
"shelljs": "^0.2.6",
"karma-junit-reporter": "^0.2.2"
},
(i.e. change protractor version to 0.24.1)
@hankduan Thank you, this solved my issue.
Should I create a pull request to angular-seed to bump the version number?
I wonder if it's better if we just always get the latest protractor. Please go ahead to create the pull request for angular to change the version.