Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I have mocha reporter for protractor?

I'm using protractor (0.22.0) for testing my app. Is this possible to have a mocha-style reporter instead of the basic jasmine one? It currenlty looks like this:

(....F...)

And I'm looking something more like:

my set of tests 1
  my test 1-1
  my test 1-2
my set of tests 2
  my test 2-1
  my test 2-2
like image 370
Erem Avatar asked Apr 22 '14 13:04

Erem


2 Answers

See the response here: Custom Jasmine reporter in Protractor tests

I'm using this module and it works perfectly: https://www.npmjs.com/package/jasmine-spec-reporter.

like image 195
Erem Avatar answered Nov 07 '22 08:11

Erem


Check out the Frameworks Protractor docs. Once you've installed Mocha, you can set Mocha options in your .protractor.conf.js file:

mochaOpts: {
  reporter: "spec",
}
like image 4
Matthew Rankin Avatar answered Nov 07 '22 06:11

Matthew Rankin