Jasmine-spec-reporter: How to disable "Expected" description of a failed spec

273 Views Asked by At

Is it possible to configure the "jasmine-spec-reporter" to NOT display the Expected description of a failed spec.

For instance, in the output below, do not print the last row "Expected true to equal false." :

 √ [ 1 ] May NOT enter the system when mandatory fields are empty
        × [ 2 ] There is NO "Null Pointer Exception"
          - Expected true to equal false.

1

There are 1 best solutions below

0
Bastien Caudan On

With 3.1.0 version, you could use spec.displayErrorMessages and summary.displayErrorMessages options:

new SpecReporter({
  spec: {
    displayErrorMessages: false
  },
  summary: {
    displayErrorMessages: false
  }
})