Skip to content

Latest commit

 

History

History
1284 lines (584 loc) · 79.2 KB

CHANGELOG.md

File metadata and controls

1284 lines (584 loc) · 79.2 KB

Change Log

All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.

6.0.2 (2022-05-05)

Bug Fixes

6.0.1 (2022-05-04)

Bug Fixes

  • plugin loader: no warn when not using plugins (#3498) (54aa298)

6.0.0 (2022-05-03)

Bug Fixes

  • core: allow parallel schedules (#3485) (bbbd514)
  • html-report: set correct background color for html report (#3456) (a72ecf1)
  • karma-runner: allow dispose during init (#3487) (4fcf148)
  • reporter: report progress of failed check results only once (#3472) (dce5882)
  • stryker-cli: allow stryker-cli integration (330ef6c)

chore

  • node: drop support for Node 12 (10d874e)

Code Refactoring

Features

  • config file: accept hidden config file by default. (#3457) (701374f)
  • mocha-runner: widen mocha peer dependency to include v10 (#3492) (0dde30f)
  • mutation testing: sort tests to improve performance (#3467) (47344d3)
  • progress: improve progressbar ETC estimate (#3469) (ec63d93)
  • react: support react 18 projects by default (#3491) (82d9bce)
  • warn slow: warn users for slow runs (#3490) (1103958)

BREAKING CHANGES

  • file: The File class is no longer part of the public api and is thus no longer exported from @stryker-mutator/api. Plugin creators shouldn't rely on it anymore.
  • progress: Reporter API method onAllMutantsMatchedWithTests has been replaced by onMutationTestingPlanReady. Please use that for your reporter plugin instead.
  • progress: Reporter API method onAllSourceFilesRead has been removed, please use onMutationTestReportReady to retrieve the source files.
  • progress: Reporter API method onSourceFileRead has been removed, please use onMutationTestReportReady to retrieve the source files.
  • node: Drop support for Node 12. Minimal version is now Node 14.18.0.

6.0.0-beta.0 (2022-03-02)

Bug Fixes

  • jest: hit limit spread over multiple files (#3446) (51308f4)

Features

Performance Improvements

BREAKING CHANGES

  • checker-api: The check method of checker plugins now receives a group of mutants and should provide a CheckResult per mutant id.
  • html reporter: Configuration option htmlReporter.baseDir is deprecated and will be removed in a later version. Please use htmlReporter.fileName instead.
  • esm config: Exporting a function (using module.exports = function(config) {}) from your stryker.conf.js file is no longer supported. This was already deprecated but now will give an error.
  • esm: StrykerJS is now a pure ESM. Please read this.
  • esm: Node 12.20 is now the min version.
  • esm: Karma v6.3 is now the min supported karma version for @stryker-mutator/karma-runner, since that version added support for async config loading
  • esm: The @stryker-mutator/jamsine-runner now requires jasmine@3.10 or higher.
  • esm: The @stryker-mutator/mocha-runner now requires mocha@7.2 or higher.
  • reload test environment: Test runner plugins must provide TestRunnerCapabilities by implementing the capabilities method.

5.6.1 (2022-01-23)

Bug Fixes

5.6.0 (2022-01-09)

Bug Fixes

  • jasmine: correct peer dependency for jasmine (#3341) (07b50a9)
  • report: dramatically improve rendering performance of HTML report (ad38c82)
  • tsconfig: force declarationDir false for non-build projects (#3313) (461f39c)

Features

  • clear-text reporter: show n/a instead of NaN (68c5c51)

5.5.1 (2021-12-02)

Bug Fixes

5.5.0 (2021-11-23)

Bug Fixes

  • instrumenter: don't mutate TS generics (#3268) (88d6eaf)
  • logging: don't log log4js category to file as well (31609a5)
  • util: clear require.cache behavior on case-insensitive file systems (#3194) (39e3d86)

Features

  • checkers: allow custom checker node args (#3179) (82c4435)
  • cli: display suggestions on error (#3216) (9ed98e8)
  • config: Add link to docs when generating a custom config (#3235) (7c999b8)
  • hit limit: infinite loop prevention in jasmine-runner (#3199) (bc792e0)
  • hit limit: infinite loop prevention in mocha-runner (f5a7d1d)
  • html: new diff-view when selecting mutants (#3263) (8b253ee)
  • init: add buildCommand question when running (#3213) (b9d5980)
  • jest-runner: support --findRelatedTests in dry run (#3234) (b2e4584)
  • mutators: Implement missing AssignmentOperatorMutator (#3203) (95b694b)

5.4.1 (2021-09-30)

Bug Fixes

  • instrumenter: don't break optional chains(#3156) (95e6b69)
  • ProgressReporter: don't render when there are no valid mutants to render (#3155) (41c4177)
  • typescript-checker: support TS 4.4 (#3178) (772e5bc)

5.4.0 (2021-09-01)

Features

  • ignore: support disable directives in source code (#3072) (701d8b3)
  • test runner: Support for disable bail (#3074) (0962232)

5.3.0 (2021-08-07)

Bug Fixes

Features

  • hit limit: infinite loop prevention in karma-runner (#3031) (fc732fc)
  • report: show status reason in the html report. (d777e49)

5.2.3 (2021-08-01)

Bug Fixes

  • karma runner: restart a browser on disconnect error (#3020) (fc5c449)
  • mocha-runner: clear error when require esm (#3015) (a835f0b), closes #3014

5.2.2 (2021-07-13)

Bug Fixes

  • schema: Resolve "No 'exports' main" error (#3004) (9034806)

5.2.1 (2021-07-02)

Bug Fixes

Features

  • html: highlight files in html report (b7876a4)
  • mutator: add the optional chaining mutator (#2988) (43ac767)

5.2.0 (2021-07-02)

Bug Fixes

  • ignore patterns: always ignore *.tsbuildinfo files (#2985) (794f103)

Features

  • 🥒: add support for cucumber-js test runner (#2970) (86d6f79)
  • instrumenter: Implement new mutant placing algorithm (#2964) (24b8bc9)

5.1.1 (2021-06-15)

Bug Fixes

  • peerDeps: update peer dependencies (05733d2)

5.1.0 (2021-06-14)

Bug Fixes

  • jest-runner: allow a different rootDir (b66a617)
  • jest-runner: use local jest version when jest@<25 (#2950) (3218c9e)

Features

  • jest-runner: allow configuration in a custom package.json (825548c)
  • jest-runner: dynamically override "testEnvironment" (#2934) (0590869)
  • jest-runner: support findRelatedTests for mutated files outside of roots (#2951) (19dccec)
  • mocha-runner: officially support mocha 9 (42848bb)

5.0.1 (2021-05-28)

Bug Fixes

5.0.0 (2021-05-14)

Bug Fixes

  • sandbox: make directory if not exists before symlinking node_modules (#2856) (40f9a1d)
  • vue-tsx: support parsing tsx script in .vue file (#2850) (dc66c28)

Features

BREAKING CHANGES

  • range: The range property is no longer present on a mutant. Note, this is a breaking change for plugin creators only.
  • options: "perTest" is now the default value for "coverageAnalysis" when the configured test runner is not "command". Explicitly set "coverageAnalysis": "off" manually to opt-out of this behavior.
  • node: Node 10 is no longer supported. Please use Node 12 or higher.
  • serialize: Having a non-JSON-serializable value in your configuration won't be sent to the child process anymore. If you really need them in your test runner configuration, you should isolate those values and put them in test runner-specific config files, loaded by the test runner plugin itself, for example, jest.config.js, karma.conf.js, webpack.config.js.
  • ignore patterns: Stryker will no longer use a git command to determine which files belong to your project. Instead, it will rely on sane defaults. You can change this behavior by defining ignorePatterns.
  • ignore patterns: The files configuration option is deprecated and will be removed in a future release. Please use ignorePatterns instead.

This:

{
  "files": ["foo.js"]
}

Is equivalent to:

{
  "ignorePatterns": ["**", "!foo.js"]
}
  • reporter api: Changes to Reporter and TestRunner plugin API of Stryker
  • jest-runner: Support for project type create-react-app-ts is dropped from the jest-runner.

4.6.0 (2021-04-16)

Features

4.5.1 (2021-03-11)

Bug Fixes

  • babel-transformer: respect top of the file comments/pragma (#2783) (ca42276)
  • instrumenter: corect mutant location in .vue and .html files (547a25c), closes #2790
  • peer-deps: use correct peer dep version (a6ca0f2)

4.5.0 (2021-03-06)

Bug Fixes

  • logging: log info about symlinking on debug (#2756) (c672e2e)
  • mutator: don't mutate string literal object methods (#2718) (964537a)
  • reporting: report test name when a hook fails (#2757) (5e062b2)
  • typescript-checker: improve error reporting (2502eba)
  • typescript-checker: resolve tsconfig files correctly (8cf9e8c)

Features

  • package: restructure package internals (#2714) (e1711d2)
  • sandbox: support symlinking of node_modules anywhere (ee66623)

4.4.1 (2021-01-27)

Bug Fixes

  • jest-runner: support custom rootDir (312f6fe)

4.4.0 (2021-01-24)

Bug Fixes

Features

4.3.1 (2020-12-25)

Note: Version bump only for package stryker-parent

4.3.0 (2020-12-25)

Features

4.2.0 (2020-12-09)

Bug Fixes

  • arithmatic-mutator: Don't mutate obvious string concat (#2648) (71f8f9a)
  • CLI help: remove non-existant logLevel 'all' (#2626) (718a7f2)

Features

  • debugging: allow passing node args to the test runner (#2609) (fdd95c0)
  • jest-runner: resolve local jest version (#2623) (1466f9a)
  • karma-runner: resolve local karma and ng version (#2622) (5b92130)
  • resporter: add json reporter (#2582) (d18c4aa)
  • timeout: add --dryRunTimeoutMinutes option (494e821)

4.1.2 (2020-11-06)

Bug Fixes

  • peerDeps: update core in peerDependencies (045dbc3)

4.1.1 (2020-11-05)

Bug Fixes

4.1.0 (2020-10-30)

Bug Fixes

  • concurrency: better default for low CPU count (#2546) (eac9199)
  • instrumenter: add missing case for .jsx files in parser (#2577) (cea94aa)
  • string-literal-mutator: don't mutate class property keys (#2544) (8c8b478)

Features

4.0.0 (2020-10-07)

Bug Fixes

  • instrumenter: don't mutate generics (#2530) (ed42e3c)
  • presets: update init templates for 4.0 release (#2526) (ec0d75e)

4.0.0-beta.10 (2020-10-05)

Bug Fixes

Features

  • instrumenter: add excludedMutations support (#2513) (bfd714f)

4.0.0-beta.9 (2020-09-30)

Bug Fixes

  • config: deprecate function based config (#2499) (8ea3c18)
  • core: fix "too many open files" (#2498) (5b7c242)
  • instrumenter: only add header when there are mutats (#2503) (8f989cc)
  • mutate config: don't warn about files not existing at the default mutate location (#2509) (66c2444), closes #2455
  • shebang: support shebang in in files (#2510) (7d2dd80)

Features

  • core: add appendPlugins command-line option (#2385) (0dec9b8)
  • core: correct initial test run timing (#2496) (4f5a37e)
  • jest-runner: deprecate "create-react-app-ts" (#2497) (0aacc7b)
  • test-runner: Add --maxTestRunnerReuse support (5919484)

BREAKING CHANGES

  • config: exporting a function from stryker.conf.js is deprecated. Please export your config as an object instead, or use a stryker.conf.json file.

Co-authored-by: Nico Jansen jansennico@gmail.com

4.0.0-beta.8 (2020-09-22)

Bug Fixes

  • instrumenter: ignore declare syntax (b1faa16)

Features

  • core: add --cleanTempDir cli option (6ef792c)
  • instrumenter: improve placement error (12e097e)

4.0.0-beta.7 (2020-09-17)

Bug Fixes

  • core: allow skipped tests when matching mutants (#2487) (09eacee), closes #2485
  • instrumenter: don't mutate constructor blocks with initialized class properties (#2484) (ca464a3), closes #2474
  • instrumenter: place mutants in if statements (#2481) (4df4102), closes #2469

4.0.0-beta.6 (2020-09-10)

Bug Fixes

4.0.0-beta.5 (2020-09-09)

Bug Fixes

  • jasmine-runner: fix memory leaks (457d807)
  • mocha-runner: don't allow custom timeout (#2463) (e90b563)
  • mocha-runner: fix memory leaks (23eede2)
  • reporters: correctly report avg tests/mutants (#2458) (582e01b)

Features

4.0.0-beta.4 (2020-08-29)

Bug Fixes

  • input files: support emojis in file names (#2430) (139f9f3)
  • input files: support emojis in file names (#2433) (b5feae2)

Features

  • api: rename test_runner2 -> test_runner (#2442) (4d3ae97)
  • jest-runner: switch mutants using env (#2416) (cad01ba)
  • karma-runner: force bail = true in all cases (ba928a1)
  • options: deprecate old stryker options (#2395) (7c637c8)
  • reporter-api: support mutation switching (67f1ed5)
  • test-runner: add nrOfTests metric (0eea448)
  • wct-runner: drop support for wct (#2440) (7c55424)

Performance Improvements

BREAKING CHANGES

  • api: Plugin creators should now use 'test_runner' instead of 'test_runner2'.
  • wct-runner: The @stryker-mutator/wct-runner package is dropped in Stryker 4.0. Please see stryker-mutator#2386 for more details. Feel free to keep using @stryker-mutator/wct-runner@3 or start a community fork. Note that support for the web-component-tester itself is minimal, you might want to consider switching to a different test runner. Stryker still supports Mocha, Jest, Jasmine and Karma.
  • reporter-api: The onMutantTested and onAllMutantsTested methods on the Reporter api have changed

4.0.0-beta.3 (2020-08-19)

Bug Fixes

Features

BREAKING CHANGES

  • exit prematurely: Stryker will now exit with exit code 1 when no tests were executed in the initial test run.
  • mocha: Mocha@<6 is deprecated and support for it will be removed in Stryker v5
  • jest-runner: Project types react and react-ts has been removed. Please use create-react-app and create-react-app-ts respectively

4.0.0-beta.2 (2020-08-07)

Bug Fixes

  • ArrowFunction mutator: don't mutate () => undefined (#2313) (310145e)
  • instrumenter: don't mutate string literals in object properties (#2354) (cd43952)
  • mutator: issue with block statement mutator (#2342) (aaa4ff6), closes #2314

Features

  • command: Support command test runner with mutation switching (#2345) (59b1cfc)
  • jest-runner: support mutation switching (#2350) (9e6e6e0)

4.0.0-beta.1 (2020-07-17)

Bug Fixes

  • Jest: Notify users of lacking Jest support (#2322) (0bbc0c1)

4.0.0-beta.0 (2020-07-10)

Bug Fixes

  • buildCommand: allow for a single command string in posix (77b6a20)
  • instrumenter: don't mutate require (963e289)
  • jasmine-runner: update deprecated api calls (#2250) (b6d6dfd)
  • karma-runner: mocha filtering with / (#2290) (3918633)
  • reporter: report event order (#2311) (ceb73a8)
  • sandbox: exec build command before symlink (bd25cd6)
  • typescript-checker: support empty files (#2310) (284a28c)

Features

BREAKING CHANGES

  • core: * --maxConcurrentTestRunners is now deprecated. Please use --concurrency instead.

3.3.1 (2020-07-04)

Bug Fixes

  • validation: don't warn about the commandRunner options (2128b9a)

3.3.0 (2020-06-16)

Features

3.2.4 (2020-05-18)

Bug Fixes

  • ts: support ts 3.9 on windows in the typescript-transpiler (#2215) (0fab74f)

3.2.3 (2020-05-15)

Bug Fixes

3.2.2 (2020-05-15)

Bug Fixes

  • options: resolve false positives in unknown options warning (#2208) (e3905f6)

3.2.1 (2020-05-15)

Bug Fixes

3.2.0 (2020-05-13)

Bug Fixes

  • utils: make sure instanceof StrykerError works (a9dea8c)
  • webpack-transpiler: add support for cache-loader (#2196) (0bcf98b)

Features

  • api: Deprecated Config in favor of StrykerOptions (dccdd91)
  • api: export the StrykerOptions JSON schema (0bb222d)
  • init: add reference to mono schema (#2162) (61953c7)
  • Jest: support overriding config (#2197) (d37b7d7), closes #2155
  • validation: validate StrykerOptions using JSON schema (5f05665)
  • validation: add validation on plugin options (#2158) (d78fe1e)
  • validation: hide stacktrace on validation error (8c5ee88)
  • validation: warn about unknown stryker config options (#2164) (8c6fd97), closes #2103

3.1.0 (2020-03-29)

Bug Fixes

  • api: allow for different api versions of File (#2124) (589de85)

Features

3.0.2 (2020-03-13)

Bug Fixes

  • nodejs requirement: set NodeJS requirement to at least Node 10 (8c08059)

3.0.1 (2020-03-12)

Bug Fixes

3.0.0 (2020-03-11)

Bug Fixes

Features

  • api: Document StrykerOptions in JSON schema (4bdb7a1)
  • config: Allow a stryker.conf.json as default config file. (#2092) (2279813)
  • core: exit code 1 when error in initial run (49c5162)
  • Dashboard reporter: upload full html report by default (#2039) (e23dbe1)
  • excludedMutations: remove deprecated mutation names (#2027) (6f7bfe1)
  • HtmlReporter: include the html reporter in the core package and add it to the default reporters (#2036) (09702d9), closes #1919
  • Initializer: Initialize config file as JSON by default (#2093) (e07d953), closes #2000
  • jest-runner: support Jest 25 (b45e872), closes #1983
  • karma-runner: disable client.clearContext (#2048) (27c0787)
  • karma-runner: use ChromeHeadless as the default browser (#2035) (18bf9b6)
  • promisified fs: use node 10 promisified functions (#2028) (1c57d8f)
  • react: change react to create-react-app (#1978) (7f34f28)
  • Reporter.onScoreCalculated: remove deprecated onScoreCalculatedevent (#2026) (9fa4175)

BREAKING CHANGES

  • core: Stryker now exists with exitCode 1 if an error of any kind occurs.
  • karma-runner: The @stryker-mutator/karma-runner will now use ChromeHeadless by default (instead of PhantomJS)
  • Reporter.onScoreCalculated: Please use the onMutationTestReportReady event and the mutation-testing-metrics npm package to calculate the mutation testing report metrics.

This

class MyReporter {
  onScoreCalculated(scoreResult) {
     // => do stuff with score result
  }
}

Becomes this:

import { calculateMetrics } from 'mutation-testing-metrics';
class MyReporter {
  onMutationTestingReportReady(report){
    const reportMetrics = calculateMetrics(report.files);
    // => do stuff with report metrics
  }
}
  • HtmlReporter: the html reporter is now enabled by default. If you don't want to use it, be sure to override the reporters configuration option.
{
  "reporters": ["progress", "clear-text"]
}
  • Dashboard reporter: The dashboard reporter will now upload a full report by default. If you don't want that, you can disable it with:
{
  "dashboard": {
    "reportType": "mutationScore"
   }
}
  • excludedMutations: removes auto-fix for the old names of mutations.

Migrating:

Almost every mutator has been renamed and/or split. Stryker will warn you about any deprecated mutator names in the mutator.excludedMutations section of your config.

To migrate, please run stryker to see if your project is affected. If this is the case, please take a look at the mutator types on the handbook (see above).

These are the changes:

Old mutation New mutation(s)
ArrayLiteral ArrayDeclaration
ArrayNewExpression ArrayDeclaration
BinaryExpression ArithmeticOperator, EqualityOperator, LogicalOperator
Block BlockStatement
BooleanSubstitution BooleanLiteral
DoStatement ConditionalExpression
ForStatement ConditionalExpression
IfStatement ConditionalExpression
PrefixUnaryExpression UnaryOperator, UpdateOperator, BooleanLiteral
PostfixUnaryExpression UpdateOperator
SwitchCase ConditionalExpression
WhileStatement ConditionalExpression

New mutations

Due to the migration, some new mutations were added to the javascript mutator.

  • The mutation ArrayDeclaration will now mutate new Array() to new Array([])
  • The mutation ArrayDeclaration will now mutate [] to ["Stryker was here"]

These mutations were already performed by the typescript mutator.

  • promisified fs: removed fsAsPromised from @stryker-mutator/util

2.5.0 (2020-01-12)

Features

  • .gitignore: add Stryker patterns to .gitignore file during initialization (#1848) (854aee0)
  • arrow mutations: add arrow mutations and refactor JavaScript mutators (#1898) (898d38b)
  • TypeScript mutator: mutate Array constructor calls without the new keyword (#1903) (aecd944), closes #1902

2.4.0 (2019-11-24)

Features

  • dashboard-reporter: add github actions ci provider (#1869) (b38b30d)
  • excludedMutations: Implement new naming of mutators (#1855) (c9b3bcb)
  • json config: support json-file config (#1853) (49495ef)
  • progress-reporter: improve reported progress ux (d7a6f88)
  • report: support upload of full report to dashboard (#1783) (fbb8102)

2.3.0 (2019-11-13)

Bug Fixes

  • core: undefined reference error in coverage recording (0a68c9c)
  • perf/angular-cli: upgrade to latest angular version and fix bugs (#1842) (4f81550)

Features

  • babel-transpiler: support object-style babel.config.js (#1762) (31410c8)

2.2.1 (2019-11-06)

Note: Version bump only for package stryker-parent

2.2.0 (2019-11-06)

Bug Fixes

  • edge cases, duplication, log output (#1720) (7f42d34)
  • jest-runner: improve error message for missing react-scripts (#1694) (313e3bf)
  • tempDir: don't resolve temp dir as input file (#1710) (bbdd02a)

Features

  • javascript-mutator: allow to override babel plugins (#1764) (ddb3d60)
  • mutant-matcher: lower memory usage (#1794) (16294e5)
  • progress-reporter: show timed out mutant count (#1818) (067df6d)
  • typescript: do not mutate interfaces (#1662) (86b2ffe)

2.1.0 (2019-09-08)

Features

  • mocha: support mocha 6.2 (feddcf1)

2.0.2 (2019-07-11)

Bug Fixes

  • child process: cleanup after dispose (#1636) (3fd5db9)
  • child process proxy: OutOfMemory detection (#1635) (4324d9f)
  • dispose: fix race condition in dispose action (124ef6a), closes #1542

2.0.1 (2019-07-02)

Bug Fixes

2.0.0 (2019-05-17)

Bug Fixes

  • vue: only mutate Vue files with <script> blocks (#1540) (ee4d27c)

Features

BREAKING CHANGES

  • es2017: changed TypeScript output target from es5 to es2017. This requires a NodeJS runtime of version 8 or higher.
  • node 6: support for Node 6 has been dropped. Node 8 or higher is now required.
  • mocha: the use of mocha version 5 and below is deprecated. Please upgrade to mocha 6 or above. See their changelog for more information about upgrading.

1.3.1 (2019-04-26)

Bug Fixes

  • clean up: prevent sandbox creation after dispose (#1527) (73fc0a8)

1.3.0 (2019-04-24)

Bug Fixes

Features

1.2.0 (2019-04-02)

Bug Fixes

  • deps: add mutation-testing-report-schema (3d40d91)
  • typescript: don't mutate declare statements (#1458) (aae3afe)

Features

  • babel-transpiler: support .js babel config files (#1422) (9e321f0)
  • html-reporter: use mutation-testing-elements (2f6df38)
  • peer-dep: update stryker core to v1.2 (d798b19)
  • reporter: add mutationReportReady event (044158d)
  • reporter: implement mutationTestReport (16ba76b)

1.1.1 (2019-03-21)

Bug Fixes

1.1.0 (2019-03-04)

Bug Fixes

  • duplicate files: make transpile always result in unique file names (#1405) (a3018d2)
  • presets: install v1.x dependencies instead of v0.x (#1434) (7edda46)

Features

1.0.3 (2019-02-26)

Bug Fixes

  • jest-runner: mark 'todo' tests as skipped (#1420) (26d813f)

1.0.2 (2019-02-13)

Bug Fixes

  • stryker init: update metadata for stryker init command (#1403) (38f269b), closes #1402

1.0.1 (2019-02-13)

Bug Fixes

  • api: remove implicit typed inject dependency (#1399) (5cae595)