headers-errors.any.html

FAILExpected8 of 18 subtests pass463 ms

Details

Test
/fetch/api/headers/headers-errors.any.html
Harness
OK

Subtests

StatusSubtestMessage
PASSCreate headers giving an array having one string as init argument
PASSCreate headers giving an array having three strings as init argument
FAILCreate headers giving bad header name as init argument
assert_throws_js: function "function() { new Headers([["invalidĀ", "Value1"]]); }" did not throw
assert_throws_js: function "function() { new Headers([["invalidĀ", "Value1"]]); }" did not throw
FAILCreate headers giving bad header value as init argument
assert_throws_js: function "function() { new Headers([["name", "invalidValueĀ"]]); }" did not throw
assert_throws_js: function "function() { new Headers([["name", "invalidValueĀ"]]); }" did not throw
FAILCheck headers get with an invalid name invalidĀ
assert_throws_js: function "function() { headers.get(name); }" did not throw
assert_throws_js: function "function() { headers.get(name); }" did not throw
PASSCheck headers get with an invalid name [object Object]
FAILCheck headers delete with an invalid name invalidĀ
assert_throws_js: function "function() { headers.delete(name); }" did not throw
assert_throws_js: function "function() { headers.delete(name); }" did not throw
PASSCheck headers delete with an invalid name [object Object]
FAILCheck headers has with an invalid name invalidĀ
assert_throws_js: function "function() { headers.has(name); }" did not throw
assert_throws_js: function "function() { headers.has(name); }" did not throw
PASSCheck headers has with an invalid name [object Object]
FAILCheck headers set with an invalid name invalidĀ
assert_throws_js: function "function() { headers.set(name, "Value1"); }" did not throw
assert_throws_js: function "function() { headers.set(name, "Value1"); }" did not throw
PASSCheck headers set with an invalid name [object Object]
FAILCheck headers set with an invalid value invalidĀ
assert_throws_js: function "function() { headers.set("name", value); }" did not throw
assert_throws_js: function "function() { headers.set("name", value); }" did not throw
FAILCheck headers append with an invalid name invalidĀ
assert_throws_js: function "function() { headers.append("invalidĀ", "Value1"); }" did not throw
assert_throws_js: function "function() { headers.append("invalidĀ", "Value1"); }" did not throw
FAILCheck headers append with an invalid name [object Object]
assert_throws_js: function "function() { headers.append("invalidĀ", "Value1"); }" did not throw
assert_throws_js: function "function() { headers.append("invalidĀ", "Value1"); }" did not throw
FAILCheck headers append with an invalid value invalidĀ
assert_throws_js: function "function() { headers.append("name", value); }" did not throw
assert_throws_js: function "function() { headers.append("name", value); }" did not throw
PASSHeaders forEach throws if argument is not callable
PASSHeaders forEach loop should stop if callback is throwing exception