blob: 2c1eab15d8565c28caa7dff4a0e55981d3b2909d [file] [log] [blame]
Test that XMLHttpRequest raises exceptions when it should.
new XMLHttpRequest()
PASS: req.setRequestHeader("Foo", "bar") threw exception Error: InvalidStateError: DOM Exception 11.
PASS: req.send(null) threw exception Error: InvalidStateError: DOM Exception 11.
open()
PASS: req.setRequestHeader() threw exception TypeError: Not enough arguments.
PASS: req.setRequestHeader("Foo") threw exception TypeError: Not enough arguments.
PASS: req.status() threw exception Error: InvalidStateError: DOM Exception 11.
PASS: req.statusText() threw exception Error: InvalidStateError: DOM Exception 11.
send()
PASS: req.send(null) threw exception Error: InvalidStateError: DOM Exception 11.
PASS: req.setRequestHeader("Foo", "bar") threw exception Error: InvalidStateError: DOM Exception 11.
PASS: req.getResponseHeader() threw exception TypeError: Not enough arguments.
PASS: req.open() threw exception TypeError: Not enough arguments.
PASS: req.open(null) threw exception TypeError: Not enough arguments.