test: update WPT for WebCryptoAPI to 19d82c57ab · nodejs/node@15d8cc9

@@ -93,6 +93,10 @@ function objectToString(obj) {

9393

// Is key a CryptoKey object with correct algorithm, extractable, and usages?

9494

// Is it a secret, private, or public kind of key?

9595

function assert_goodCryptoKey(key, algorithm, extractable, usages, kind) {

96+

if (typeof algorithm === "string") {

97+

algorithm = { name: algorithm };

98+

}

99+96100

var correctUsages = [];

9710198102

var registeredAlgorithmName;

@@ -203,6 +207,7 @@ function allAlgorithmSpecifiersFor(algorithmName) {

203207

results.push({name: algorithmName, namedCurve: curveName});

204208

});

205209

} else if (algorithmName.toUpperCase().substring(0, 1) === "X" || algorithmName.toUpperCase().substring(0, 2) === "ED") {

210+

results.push(algorithmName);

206211

results.push({ name: algorithmName });

207212

}

208213