🚀 DAY 5 OF LAUNCH WEEK:Introducing Webhook Events for Alert Changes.Learn more →
Socket
Book a DemoInstallSign in
Socket

@cucumber/json-to-messages

Package Overview
Dependencies
Maintainers
2
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cucumber/json-to-messages

Translate legacy JSON to messages

latest
Source
npmnpm
Version
10.0.0
Version published
Weekly downloads
372
-56.13%
Maintainers
2
Weekly downloads
 
Created
Source

cucumber/json-to-messages

A library to translate legacy JSON output from various cucumber implementations to cucumber-messages.

Currently supports output from:

  • behave
  • cucumber-java
  • cucumber-javascript
  • cucumber-ruby

Installing

You can install this tool using npm:

npm install @cucumber/json-to-messages

Using the CLI

Send the content of your json file to the CLI:

cat my_report.json | ./node_modules/.bin/json-to-messages > my_report.ndjson

By default, the tool will detect the cucumber implementation used to generate the report but you can specify it manually:

cat my_report.json | ./node_modules/.bin/json-to-messages --implementation cucumber-js > my_report.ndjson

Using as a library

import { jsonToMessages } from '@cucumber/json-to-messages'

const JSONs: Readable = ... // The JSON reports to translate
const outputStream: Writable = ... // A stream to write the messages to
jsonToMessages(JSONs, outputStream)

Keywords

cucumber

FAQs

Package last updated on 08 Jul 2021

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