Index: LayoutTests/crypto/importKey.html |
diff --git a/LayoutTests/crypto/importKey.html b/LayoutTests/crypto/importKey.html |
index a7481ccdd286bfbbcf57b209221c9045cb816d90..fcdc3e24447427abc30821367f59df75c953b880 100644 |
--- a/LayoutTests/crypto/importKey.html |
+++ b/LayoutTests/crypto/importKey.html |
@@ -112,17 +112,6 @@ Promise.resolve(null).then(function() { |
bytesShouldMatchHexString("key.algorithm.publicExponent", "010001", key.algorithm.publicExponent); |
shouldBe("key.usages.join(',')", "''") |
- // Import a "raw" key without specifying the algorithm. |
- keyFormat = "raw"; |
- data = asciiToUint8Array("16 bytes of key!"); |
- algorithm = null; |
- extractable = false; |
- keyUsages = []; |
- |
- return crypto.subtle.importKey(keyFormat, data, algorithm, extractable, keyUsages); |
-}).then(undefined, function(result) { |
- debug("rejected with " + result); |
- |
keyFormat = "raw"; |
data = asciiToUint8Array(""); |
algorithm = aesCbc; |
@@ -147,6 +136,9 @@ Promise.resolve(null).then(function() { |
shouldThrow("crypto.subtle.importKey(keyFormat, [], algorithm, extractable, keyUsages)"); |
shouldThrow("crypto.subtle.importKey(keyFormat, null, algorithm, extractable, keyUsages)"); |
+ // Invalid algorithm |
+ shouldThrow("crypto.subtle.importKey(keyFormat, data, null, extractable, keyUsages)"); |
+ |
// Missing hash parameter for HMAC. |
shouldRejectPromiseWithNull("crypto.subtle.importKey(keyFormat, data, {name: 'hmac'}, extractable, keyUsages)"); |