Socket
Book a DemoInstallSign in
Socket

@mochajs/json-file-reporter

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mochajs/json-file-reporter

JSON file reporter for Mocha

latest
Source
npmnpm
Version
1.3.0
Version published
Weekly downloads
12K
-19.6%
Maintainers
1
Weekly downloads
 
Created
Source

npm version JavaScript Style Guide

@mochajs/json-file-reporter

JSON file reporter for Mocha

Installation

$ npm i -D @mochajs/json-file-reporter

Usage

Use --reporter in your test command.

{
  "scripts": {
    "test": "mocha --reporter @mochajs/json-file-reporter"
  }
}

Or, add reporter to your configuration file.

{
  "reporter": "@mochajs/json-file-reporter"
}

Options

output

By default, it will output to report.json. To write to other file, use --reporter-options in your test command.

{
  "scripts": {
    "test": "mocha --reporter @mochajs/json-file-reporter --reporter-options output=filename.json"
  }
}

Or, add reporter-option to your configuration file.

{
  "reporter": "@mochajs/json-file-reporter",
  "reporter-option": [
    "output=filename.json"
  ]
}

Keywords

mocha

FAQs

Package last updated on 16 Oct 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts