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

Add tests to improve internal/crypto/diffiehellman.js coverage #17728

Closed
wants to merge 4 commits into from
Closed

Add tests to improve internal/crypto/diffiehellman.js coverage #17728

wants to merge 4 commits into from

Conversation

Leko
Copy link
Contributor

@Leko Leko commented Dec 18, 2017

I added these tests

  • Call crypto.ECDH without new keyword
  • Call crypto.DiffieHellmanGroup without new keyword
  • Call crypto.DiffieHellman without new keyword

Current coverage is here: https://coverage.nodejs.org/coverage-1fa59b4c7e575ca7/root/internal/crypto/diffiehellman.js.html

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines
Affected core subsystem(s)

test

@nodejs-github-bot nodejs-github-bot added the test Issues and PRs related to the tests. label Dec 18, 2017
@Leko Leko changed the title Add tests to improve internal/crypto/diffiehellman.js Add tests to improve internal/crypto/diffiehellman.js coverage Dec 18, 2017

{
const ECDH = crypto.ECDH;
const dh = ECDH('prime256v1');
Copy link
Member

Choose a reason for hiding this comment

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

Nit: how about changing the variable name to ecdh?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thank you for your review.
I fixed variable names.

DiffieHellmanGroup -> dhg
ECDH -> ecdh
@maclover7
Copy link
Contributor

@maclover7
Copy link
Contributor

Landing...

@maclover7 maclover7 self-assigned this Dec 21, 2017
@maclover7
Copy link
Contributor

Thank you for your contribution, landed in 410ce21.
❤️ 💚 💙 💛 💜

@maclover7 maclover7 closed this Dec 21, 2017
maclover7 pushed a commit to maclover7/node that referenced this pull request Dec 21, 2017
PR-URL: nodejs#17728
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
@Leko Leko deleted the test_crypto_diffiehellman branch December 22, 2017 00:10
MylesBorins pushed a commit that referenced this pull request Jan 8, 2018
PR-URL: #17728
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
MylesBorins pushed a commit that referenced this pull request Jan 9, 2018
PR-URL: #17728
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
MylesBorins pushed a commit that referenced this pull request Jan 9, 2018
PR-URL: #17728
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
@MylesBorins MylesBorins mentioned this pull request Jan 10, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
test Issues and PRs related to the tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants