Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description:
Successfully installed the StrykerJS tool.
StrykerJS is a mutation testing framework designed for JavaScript projects. It helps ensure code quality by introducing small changes (mutants) and verifying if your tests can detect these changes. This ensures your tests are robust and that untested parts of your code are exposed. StrykerJS supports projects using TypeScript, React, Angular, VueJS, Svelte, and NodeJS.
The current version installed is 8.6.
How to use StrykerJS:
In order to run Stryker to mutation test use the following command:
npx stryker run
You can also try running with trace logging as follows:
npx stryker run --logLevel trace
Files Installed:
When installing Stryker the following 2 files were created/modified, .gitignore and stryker.config.json. Later, I copied the stryker dependency from the local
package.json
intoinstall/package.json
to pipeline the stryker installation into the installation of NodeBB packages.Testing:
We used stryker to run the codebase, the results can be seen in the screenshot below. It identified that 548 of 11026 file(s) to be mutated, and highlighted some of the errors.