Skip to content

Commit

Permalink
test: fix variable name for non-RSA keys
Browse files Browse the repository at this point in the history
PR-URL: #36912
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
tniessen committed Jan 15, 2021
1 parent 0f57902 commit ccc6776
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/parallel/test-webcrypto-sign-verify-rsa.js
Expand Up @@ -23,7 +23,7 @@ async function testVerify({
noVerifyPublicKey,
privateKey,
hmacKey,
rsaKeys
ecdsaKeys
] = await Promise.all([
subtle.importKey(
'spki',
Expand Down Expand Up @@ -85,7 +85,7 @@ async function testVerify({
});

await assert.rejects(
subtle.verify(algorithm, rsaKeys.publicKey, signature, plaintext), {
subtle.verify(algorithm, ecdsaKeys.publicKey, signature, plaintext), {
message: /Unable to use this key to verify/
});

Expand Down Expand Up @@ -138,7 +138,7 @@ async function testSign({
noSignPrivateKey,
privateKey,
hmacKey,
rsaKeys,
ecdsaKeys
] = await Promise.all([
subtle.importKey(
'spki',
Expand Down Expand Up @@ -205,7 +205,7 @@ async function testSign({
});

await assert.rejects(
subtle.sign(algorithm, rsaKeys.privateKey, plaintext), {
subtle.sign(algorithm, ecdsaKeys.privateKey, plaintext), {
message: /Unable to use this key to sign/
});
}
Expand Down

0 comments on commit ccc6776

Please sign in to comment.