| Index: LayoutTests/crypto/importKey-badParameters.html
|
| diff --git a/LayoutTests/crypto/importKey-badParameters.html b/LayoutTests/crypto/importKey-badParameters.html
|
| index 04e8c9c260c2f2676e128b42cabaed16239d65dd..9ce7c4c3ecd35386d3ff3dbc7ab9b7c879838cf5 100644
|
| --- a/LayoutTests/crypto/importKey-badParameters.html
|
| +++ b/LayoutTests/crypto/importKey-badParameters.html
|
| @@ -21,14 +21,25 @@ var extractable = true;
|
| // FIXME: http://crbug.com/262383
|
| //shouldThrow("crypto.subtle.importKey('raw', aesKeyBytes, aesCbc, extractable, undefined)");
|
|
|
| -// Invalid data
|
| -shouldThrow("crypto.subtle.importKey('raw', [], aesCbc, extractable, ['encrypt'])");
|
| -shouldThrow("crypto.subtle.importKey('raw', null, aesCbc, extractable, ['encrypt'])");
|
| +Promise.resolve(null).then(function() {
|
| + // Invalid data
|
| + return crypto.subtle.importKey('raw', [], aesCbc, extractable, ['encrypt']);
|
| +}).then(failAndFinishJSTest, function(result) {
|
| + error = result;
|
| + shouldBeNull("error");
|
| +
|
| + // Invalid data
|
| + return crypto.subtle.importKey('raw', null, aesCbc, extractable, ['encrypt']);
|
| +}).then(failAndFinishJSTest, function(result) {
|
| + error = result;
|
| + shouldBeNull("error");
|
|
|
| -// Invalid algorithm
|
| -shouldThrow("crypto.subtle.importKey('raw', aesCbc, null, extractable, ['encrypt'])");
|
| + // Invalid algorithm
|
| + return crypto.subtle.importKey('raw', aesKeyBytes, null, extractable, ['encrypt']);
|
| +}).then(failAndFinishJSTest, function(result) {
|
| + error = result;
|
| + shouldBeNull("error");
|
|
|
| -Promise.resolve(null).then(function() {
|
| // Invalid format.
|
| return crypto.subtle.importKey('invalid format', aesKeyBytes, aesCbc, extractable, ['encrypt']);
|
| }).then(failAndFinishJSTest, function(result) {
|
|
|