Git Product home page Git Product logo

mocha-circleci-reporter's Introduction

mocha-circleci-reporter Build Status

A Mocha reporter specifically for Circle CI.

Getting Started

Install the reporter as a development dependency:

npm install mocha --save-dev
npm install mocha-circleci-reporter --save-dev

Update your package.json to use the reporter when running Mocha:

{
  "name": "my-package",
  "version": "0.0.1",
  "scripts": {
    "test": "node_modules/.bin/mocha --reporter mocha-circleci-reporter test/*.js"
  }
}

Background

Why another reporter?

As of Mocha 2.x, its not possible to use multple reporters out of the box. This complicates things when dealing with CI systems like Circle CI that require a format such as jUnit XML as a lot of the goodness that is written to console when running the default reporter (Spec).

To overcome this, the mocha-circleci-reporter report combines both the builtin Spec and mocha-junit-report reporters.

Example spec output:

spec_output.jpg

Example jUnit output:

spec_output.jpg

Mocha 3.x

There is work underway in Mocha 3.x to move to a plugin architecture that would make multiple reporters dead simple, until then I hope this simplifies things.

mochajs/mocha#1457

mocha-circleci-reporter's People

Contributors

sandcastle avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.