🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@stryker-mutator/api

Package Overview
Dependencies
Maintainers
4
Versions
103
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@stryker-mutator/api

The api for the extendable JavaScript mutation testing framework Stryker

9.0.1
latest
Source
npm
Version published
Weekly downloads
305K
10.63%
Maintainers
4
Weekly downloads
 
Created

What is @stryker-mutator/api?

@stryker-mutator/api is a part of the Stryker Mutator framework, which is used for mutation testing in JavaScript and TypeScript projects. It provides a set of APIs that allow developers to integrate and extend the mutation testing capabilities of Stryker.

What are @stryker-mutator/api's main functionalities?

Mutator API

The Mutator API allows developers to create custom mutators that define how code should be mutated during testing. This is useful for extending the mutation testing capabilities to cover more specific or custom scenarios.

const { Mutator } = require('@stryker-mutator/api/mutant');

class MyMutator extends Mutator {
  mutate(node) {
    // Custom mutation logic
  }
}

Reporter API

The Reporter API provides a way to create custom reporters that can handle and display the results of mutation testing. This allows for customized reporting formats and integration with other tools.

const { Reporter } = require('@stryker-mutator/api/report');

class MyReporter extends Reporter {
  onMutantTested(result) {
    console.log(`Mutant ${result.id} tested with status ${result.status}`);
  }
}

Test Framework API

The Test Framework API allows developers to integrate custom test frameworks with Stryker. This is useful for supporting additional testing frameworks that are not natively supported by Stryker.

const { TestFramework } = require('@stryker-mutator/api/test_framework');

class MyTestFramework extends TestFramework {
  constructor() {
    super();
    // Custom test framework initialization
  }
}

Other packages similar to @stryker-mutator/api

Keywords

mutation testing

FAQs

Package last updated on 14 May 2025

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