Index: LayoutTests/fast/dom/set-custom-validity-with-too-few-arguments.html |
diff --git a/LayoutTests/fast/dom/set-custom-validity-with-too-few-arguments.html b/LayoutTests/fast/dom/set-custom-validity-with-too-few-arguments.html |
index 2a6960de5506b209d85d0d9664e402ecd1a1d11b..d8d59336ba1355b5f150e416dfc0c4dcd1f8f11e 100644 |
--- a/LayoutTests/fast/dom/set-custom-validity-with-too-few-arguments.html |
+++ b/LayoutTests/fast/dom/set-custom-validity-with-too-few-arguments.html |
@@ -9,15 +9,51 @@ description('Test how setCustomValidity reacts to too few arguments.'); |
var b = document.createElement('button'); |
shouldThrow("b.setCustomValidity()"); |
+shouldBeUndefined("b.setCustomValidity(null)"); |
philipj_slow
2015/07/06 12:36:18
shouldNotThrow() would be a more explicit way of s
shiva.jm
2015/07/07 10:33:42
Done.
|
+shouldBeUndefined("b.setCustomValidity('')"); |
+shouldBeUndefined("b.setCustomValidity(undefined)"); |
var fs = document.createElement('fieldset'); |
shouldThrow("fs.setCustomValidity()"); |
+shouldBeUndefined("fs.setCustomValidity(null)"); |
+shouldBeUndefined("fs.setCustomValidity('')"); |
+shouldBeUndefined("fs.setCustomValidity(undefined)"); |
var i = document.createElement('input'); |
shouldThrow("i.setCustomValidity()"); |
+shouldBeUndefined("i.setCustomValidity(null)"); |
+shouldBeUndefined("i.setCustomValidity('')"); |
+shouldBeUndefined("i.setCustomValidity(undefined)"); |
var k = document.createElement('keygen'); |
shouldThrow("k.setCustomValidity()"); |
+shouldBeUndefined("k.setCustomValidity(null)"); |
+shouldBeUndefined("k.setCustomValidity('')"); |
+shouldBeUndefined("k.setCustomValidity(undefined)"); |
+ |
+var ob = document.createElement('object'); |
+shouldThrow("ob.setCustomValidity()"); |
+shouldBeUndefined("ob.setCustomValidity(null)"); |
+shouldBeUndefined("ob.setCustomValidity('')"); |
+shouldBeUndefined("ob.setCustomValidity(undefined)"); |
+ |
+var ou = document.createElement('output'); |
+shouldThrow("ou.setCustomValidity()"); |
+shouldBeUndefined("ou.setCustomValidity(null)"); |
+shouldBeUndefined("ou.setCustomValidity('')"); |
+shouldBeUndefined("ou.setCustomValidity(undefined)"); |
+ |
+var s = document.createElement('select'); |
+shouldThrow("s.setCustomValidity()"); |
+shouldBeUndefined("s.setCustomValidity(null)"); |
+shouldBeUndefined("s.setCustomValidity('')"); |
+shouldBeUndefined("s.setCustomValidity(undefined)"); |
+ |
+var ta = document.createElement('textarea'); |
+shouldThrow("ta.setCustomValidity()"); |
+shouldBeUndefined("ta.setCustomValidity(null)"); |
+shouldBeUndefined("ta.setCustomValidity('')"); |
+shouldBeUndefined("ta.setCustomValidity(undefined)"); |
</script> |
</body> |
</html> |