stryker-mutator / stryker-js

Mutation testing for JavaScript and friends
https://stryker-mutator.io
Apache License 2.0
2.55k stars 242 forks source link

[DRAFT] Mutation server #4877

Open jaspervdveen opened 1 month ago

jaspervdveen commented 1 month ago

This pull request introduces a mutation server within the core module of StrykerJS, implementing the Mutation Server Protocol. This server facilitates communication between StrykerJS and external clients, specifically the (unpublished) vscode-stryker IDE extension.

The Mutation Server Protocol is designed to enhance the integration and interaction between Stryker mutation testing frameworks and development tools, offering a standardized method for communication. The protocol leverages JSON-RPC messages for its operations, ensuring a consistent and efficient communication pattern. The detailed reasoning and decision-making process for the Mutation Server Protocol can be found in the corresponding ADR (Architectural Decision Record). As of now, messages are transported using a web socket, the corresponding ADR for this decision can be found here.

To further enhance modularity and reusability, there are plans to extract the Mutation Server Protocol into a separate npm package. This will allow other projects to easily adopt and implement the protocol.

The VS Code extension, the Mutation Server Protocol and its implementation in StrykerJS were developed as part of my internship. I am eager to hear your thoughts and feedback on this implementation.