Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): update stryker monorepo to v3 (major) #31

Merged
merged 1 commit into from
Mar 11, 2020

Conversation

renovate[bot]
Copy link

@renovate renovate bot commented Mar 11, 2020

This PR contains the following updates:

Package Type Update Change
@stryker-mutator/core devDependencies major 2.5.0 -> 3.0.0
@stryker-mutator/html-reporter devDependencies major 2.5.0 -> 3.0.0
@stryker-mutator/javascript-mutator devDependencies major 2.5.0 -> 3.0.0
@stryker-mutator/jest-runner devDependencies major 2.5.0 -> 3.0.0

Release Notes

stryker-mutator/stryker

v3.0.0

Compare Source

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.


Renovate configuration

📅 Schedule: At any time (no schedule defined).

🚦 Automerge: Enabled.

♻️ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about these updates again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by WhiteSource Renovate. View repository job log here.

@jimmyandrade
Copy link
Member

Good news coming from stryker-mutator/stryker-js#1983 (comment)

@renovate renovate bot merged commit 5019537 into master Mar 11, 2020
@renovate renovate bot deleted the renovate/major-stryker-monorepo branch March 11, 2020 20:43
@jimmyandrade jimmyandrade self-requested a review March 11, 2020 21:37
Copy link
Member

@jimmyandrade jimmyandrade left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants