Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion test/fixtures/wpt/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Last update:
- wasm/jsapi: https://github.com/web-platform-tests/wpt/tree/cde25e7e3c/wasm/jsapi
- wasm/webapi: https://github.com/web-platform-tests/wpt/tree/fd1b23eeaa/wasm/webapi
- web-locks: https://github.com/web-platform-tests/wpt/tree/10a122a6bc/web-locks
- WebCryptoAPI: https://github.com/web-platform-tests/wpt/tree/591c95ce61/WebCryptoAPI
- WebCryptoAPI: https://github.com/web-platform-tests/wpt/tree/19d82c57ab/WebCryptoAPI
- webidl/ecmascript-binding/es-exceptions: https://github.com/web-platform-tests/wpt/tree/2f96fa1996/webidl/ecmascript-binding/es-exceptions
- webmessaging/broadcastchannel: https://github.com/web-platform-tests/wpt/tree/6495c91853/webmessaging/broadcastchannel
- webstorage: https://github.com/web-platform-tests/wpt/tree/1291340aaa/webstorage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,27 @@
// helper functions that generate all possible test parameters for
// different situations.
function getValidKeyData(algorithm) {
return validKeyData[algorithm.name];
return validKeyData[algorithm.name || algorithm];
}

function getBadKeyLengthData(algorithm) {
return badKeyLengthData[algorithm.name];
return badKeyLengthData[algorithm.name || algorithm];
}

function getMissingJWKFieldKeyData(algorithm) {
return missingJWKFieldKeyData[algorithm.name];
return missingJWKFieldKeyData[algorithm.name || algorithm];
}

function getMismatchedJWKKeyData(algorithm) {
return mismatchedJWKKeyData[algorithm.name];
return mismatchedJWKKeyData[algorithm.name || algorithm];
}

function getMismatchedKtyField(algorithm) {
return mismatchedKtyField[algorithm.name];
return mismatchedKtyField[algorithm.name || algorithm];
}

function getMismatchedCrvField(algorithm) {
return mismatchedCrvField[algorithm.name];
return mismatchedCrvField[algorithm.name || algorithm];
}

var validKeyData = {
Expand Down
5 changes: 5 additions & 0 deletions test/fixtures/wpt/WebCryptoAPI/util/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,10 @@ function objectToString(obj) {
// Is key a CryptoKey object with correct algorithm, extractable, and usages?
// Is it a secret, private, or public kind of key?
function assert_goodCryptoKey(key, algorithm, extractable, usages, kind) {
if (typeof algorithm === "string") {
algorithm = { name: algorithm };
}

var correctUsages = [];

var registeredAlgorithmName;
Expand Down Expand Up @@ -203,6 +207,7 @@ function allAlgorithmSpecifiersFor(algorithmName) {
results.push({name: algorithmName, namedCurve: curveName});
});
} else if (algorithmName.toUpperCase().substring(0, 1) === "X" || algorithmName.toUpperCase().substring(0, 2) === "ED") {
results.push(algorithmName);
results.push({ name: algorithmName });
}

Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/wpt/versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
"path": "web-locks"
},
"WebCryptoAPI": {
"commit": "591c95ce6174690b92833cd92859ce2807714591",
"commit": "19d82c57abc7494bdc459a338c5dcfd79e818b4a",
"path": "WebCryptoAPI"
},
"webidl/ecmascript-binding/es-exceptions": {
Expand Down
Loading