summaryrefslogtreecommitdiff
path: root/cli/tests/node_compat/test/parallel/test-crypto-dh.js
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests/node_compat/test/parallel/test-crypto-dh.js')
-rw-r--r--cli/tests/node_compat/test/parallel/test-crypto-dh.js26
1 files changed, 13 insertions, 13 deletions
diff --git a/cli/tests/node_compat/test/parallel/test-crypto-dh.js b/cli/tests/node_compat/test/parallel/test-crypto-dh.js
index b436207ac..bcf0c6764 100644
--- a/cli/tests/node_compat/test/parallel/test-crypto-dh.js
+++ b/cli/tests/node_compat/test/parallel/test-crypto-dh.js
@@ -187,22 +187,22 @@ if (false) {
message: 'The "curve" argument must be of type string. ' +
'Received undefined'
});
-
- assert.throws(
- function() {
- crypto.getDiffieHellman('unknown-group');
- },
- {
- name: 'Error',
- code: 'ERR_CRYPTO_UNKNOWN_DH_GROUP',
- message: 'Unknown DH group'
- },
- 'crypto.getDiffieHellman(\'unknown-group\') ' +
- 'failed to throw the expected error.'
- );
}
assert.throws(
+ function() {
+ crypto.getDiffieHellman('unknown-group');
+ },
+ {
+ name: 'Error',
+ code: 'ERR_CRYPTO_UNKNOWN_DH_GROUP',
+ message: 'Unknown DH group'
+ },
+ 'crypto.getDiffieHellman(\'unknown-group\') ' +
+ 'failed to throw the expected error.'
+);
+
+assert.throws(
() => crypto.createDiffieHellman('', true),
{
code: 'ERR_INVALID_ARG_TYPE'