Index: LayoutTests/fast/dom/css-mediarule-functions.html |
diff --git a/LayoutTests/fast/dom/css-mediarule-functions.html b/LayoutTests/fast/dom/css-mediarule-functions.html |
index b6d3c488236cc85a6ba1e246df603bbe45fbe140..381ec5a133e9d04060c7ac3f4f317396aa1c01ae 100644 |
--- a/LayoutTests/fast/dom/css-mediarule-functions.html |
+++ b/LayoutTests/fast/dom/css-mediarule-functions.html |
@@ -66,6 +66,16 @@ |
// Test that insertRule raises an exception for illegally placed rules. |
try { |
+ // NamespaceRule illegal inside a MediaRule. |
+ var index = mediaRule.insertRule("@namespace mynamespace url(http://www.w3.org/1999/xhtml);", mediaRule.cssRules.length); |
+ log("FAIL: an exception should have been thrown!"); |
+ } catch (e) { |
+ if (e.code == 3) |
+ log("PASS: Exception raised successfully. Type: " + e); |
+ else |
+ log("FAIL: wrong exception type thrown. " + e.code + " was thrown, should of been Error: HierarchyRequestError: DOM Exception 3!"); |
+ } |
+ try { |
// ImportRule illegal inside a MediaRule. |
var index = mediaRule.insertRule("@import url(sheet.css);", mediaRule.cssRules.length); |
log("FAIL: an exception should have been thrown!"); |