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

fix(jest): vulnerability fix #139

Merged
merged 56 commits into from
Oct 12, 2021
Merged

fix(jest): vulnerability fix #139

merged 56 commits into from
Oct 12, 2021

Conversation

Andras-Csanyi
Copy link
Contributor

@Andras-Csanyi Andras-Csanyi commented Oct 7, 2021

PR summary

This PR brings a major update for jest (v27), and covers the consequences of it.

  • using done has been removed from unit tests
  • using done is removed from integration tests, but the methods are not refactored to async
  • using done is removed from examples too, and all the examples are refactored to async due to using some custom logic around console.log and console.warn
  • integration tests run ok, expect when used account related issues (they might be rotated already), these tests also can manage that when no .env file provided (in this case the test skips execution)
  • examples run ok, expect when used account related issues (they might be rotated already so we can't use the account anymore), the examples also can manage that when no .env file provided

Possible follow up tasks:

  • refactor integration tests to async from promise
  • modify the generated integration tests and examples accordingly
  • re-gen example-json files for SDKs

We also have to figure out whether async pattern or promise pattern is the preferred one in the reference.

PR Checklist

Please make sure that your PR fulfills the following requirements:

  • The commit message follows the Angular Commit Message Guidelines.
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

Current vs new behavior

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

@Andras-Csanyi Andras-Csanyi self-assigned this Oct 7, 2021
@codecov
Copy link

codecov bot commented Oct 7, 2021

Codecov Report

Merging #139 (cc17646) into main (b046997) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##              main      #139   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           22        22           
  Lines         3616      3616           
  Branches       437       437           
=========================================
  Hits          3616      3616           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b046997...cc17646. Read the comment docs.

Copy link
Member

@dpopp07 dpopp07 left a comment

Choose a reason for hiding this comment

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

I admit I didn't look at every file but I feel I reviewed a representative sample since you made the same changes to all files. The changes look great! 👍

examples/enterprise-billing-units.v1.test.js Show resolved Hide resolved
@Andras-Csanyi Andras-Csanyi merged commit ff04e5e into main Oct 12, 2021
ibm-devx-sdk pushed a commit that referenced this pull request Oct 12, 2021
## [0.21.1](v0.21.0...v0.21.1) (2021-10-12)

### Bug Fixes

* **jest:** vulnerability fix ([#139](#139)) ([ff04e5e](ff04e5e))
@ibm-devx-sdk
Copy link

🎉 This PR is included in version 0.21.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@padamstx padamstx deleted the 2917_setvalue_vuln_issue branch November 19, 2021 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants