npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

testgear-adapter-cucumber

v1.1.0

Published

Adapter provides formatter for cucumber output and some additional methods to Cucumber world.

Downloads

5

Readme

Test Gear TMS adapters for Cucumber

Test Gear

Getting Started

Compatibility

| TestGear | Adapter | |----------|---------| | 3.5 | 1.0 | | 4.0 | 1.1 |

Installation

npm install testgear-adapter-cucumber

Usage

API client

To use adapter you need to install testgear-api-client:

npm install testgear-api-client

Configuration

Create testgearFormatter.js file in the root directory of the project:

const { testGearFormatter } = require('testgear-adapter-cucumber');

module.exports = class CustomFormatter extends TestGearFormatter {
  constructor(options) {
    super(options, {
      url: '<url>',
      privateToken: '<token>',
      projectId: '<id>',
      configurationId: '<id>',
      testRunId: '<optional id>',
    });
  }
};

And fill object with your configuration. Formatter sends results to TMS.

TestRunId is optional. If it's not provided than it create automatically.

Add to cucumber.js file

module.exports = {
  default:
    '-f ./testgearFormatter.js',
};

Tags

Formatter provides additional methods to World:

  • addMessage - adds message to autotest
  • addLinks - adds links to autotest
  • addAttachments - uploads specified to TMS and links to test run
When('Something happens', function () {
  this.addMessage('💔');
  this.addLinks([
    {
      url: 'http://github.com',
    },
    {
      url: 'https://wikipedia.org',
      title: 'Wikipedia',
      description: 'The free encyclopedia',
      type: 'Related',
      hasInfo: true,
    },
  ]);
  this.addAttachments(['path/to/file.txt']);
});

Cucumber tags can be used to specify information about autotest.

Only those specified above the Scenario are taken into account

  • @ExternalId - Unique identifier of autotest (Required)
  • @Title - Title that is displayed on autotest page
  • @DisplayName - Name that is displayed in autotests table
  • @Description - Autotest description
  • @Link - can be specified either in JSON (@Link={"url":"http://google.com","hasInfo":true,"description":"GoogleDescription","title":"Google","type":"Defect"}) or in text (@Link=http://google.com)
  • @Label - Label that is going to be linked to autotest
  • @WorkItemId - Work item's ID to which autotest is going to be linked

Examples

Tags

Feature: Tags
  @DisplayName=GoogiliGoogle
  @Description=Cannot_Write_With_Spaces
  @ExternalId=344
  @Link=http://google.com
  @Link=http://vk.com
  @Label=Maths
  @Label=School
  Scenario: Scenario with links
    When 2+2
    Then Result is 4
  @Title=LINKS
  @ExternalId=343
  @Link={"url":"http://google.com","hasInfo":true,"description":"GoogleDescription","title":"Google","type":"Defect"}
  Scenario: Scenario with link obj
    When 2+2
    Then Result is 4

Parameterized test

Feature: Rule
  Tests that use Rule
  @ExternalId=999
  Scenario: Summing
    When <left>+<right>
    Then Result is <result>

    Examples: Options
      Examples show different options
      | left | right | result |
      | 1    | 1     | 3      |
      | 9    | 9     | 18     |

Contributing

You can help to develop the project. Any contributions are greatly appreciated.

  • If you have suggestions for adding or removing projects, feel free to open an issue to discuss it, or directly create a pull request after you edit the README.md file with necessary changes.
  • Please make sure you check your spelling and grammar.
  • Create individual PR for each suggestion.
  • Please also read through the Code Of Conduct before posting your first idea as well.

License

Distributed under the Apache-2.0 License. See LICENSE for more information.