Why is testem reporting all the tests as a single test?

59 Views Asked by At

I have multiple passing tests, but everything is reported as a single test.

This is a Node app, it never runs in the browser.

Output

1..1

tests 1

pass 1

Testem config:

module.exports = {
  src_files: [
    'test/**/*.js'
  ],
  launchers: {
    Node: {
      command: './node_modules/.bin/mocha'
    }
  },
  launch_in_ci: ['Node'],
  launch_in_dev: ['Node'],
};

Mocha opts:

--recursive
--bail
--sort
--full-trace
--no-timeouts
--ui bdd
--colors
--exit

Repro: https://github.com/givanse/testem-mocha-repro

1

There are 1 best solutions below

0
givanse On

To solve this you have to specify the reporter and protocol in the Testem config like this:

  launchers: {
    Node: {
      command: './node_modules/.bin/mocha -R tap',
      protocol: 'tap'
    }
  },