blob: 069913417458802ac7a7075dffac7cd58c959b81 [file] [log] [blame]
This tests the constructor for the HashChangeEvent DOM class.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS new HashChangeEvent('eventType').bubbles is false
PASS new HashChangeEvent('eventType').cancelable is false
PASS new HashChangeEvent('eventType').oldURL is ""
PASS new HashChangeEvent('eventType').newURL is ""
PASS new HashChangeEvent('eventType', { bubbles: false }).bubbles is false
PASS new HashChangeEvent('eventType', { bubbles: true }).bubbles is true
PASS new HashChangeEvent('eventType', { cancelable: false }).cancelable is false
PASS new HashChangeEvent('eventType', { cancelable: true }).cancelable is true
PASS new HashChangeEvent('eventType', { oldURL: 'doremi' }).oldURL is "doremi"
PASS new HashChangeEvent('eventType', { oldURL: '' }).oldURL is ""
PASS new HashChangeEvent('eventType', { oldURL: undefined }).oldURL is ""
PASS new HashChangeEvent('eventType', { oldURL: null }).oldURL is "null"
PASS new HashChangeEvent('eventType', { oldURL: false }).oldURL is "false"
PASS new HashChangeEvent('eventType', { oldURL: true }).oldURL is "true"
PASS new HashChangeEvent('eventType', { oldURL: 12345 }).oldURL is "12345"
PASS new HashChangeEvent('eventType', { oldURL: 18446744073709551615 }).oldURL is "18446744073709552000"
PASS new HashChangeEvent('eventType', { oldURL: NaN }).oldURL is "NaN"
PASS new HashChangeEvent('eventType', { oldURL: [] }).oldURL is ""
PASS new HashChangeEvent('eventType', { oldURL: [1, 2, 3] }).oldURL is "1,2,3"
PASS new HashChangeEvent('eventType', { oldURL: {doremi: 12345} }).oldURL is "[object Object]"
PASS new HashChangeEvent('eventType', { oldURL: {valueOf: function () { return 'doremi'; } } }).oldURL is "[object Object]"
PASS new HashChangeEvent('eventType', { newURL: 'doremi' }).newURL is "doremi"
PASS new HashChangeEvent('eventType', { newURL: '' }).newURL is ""
PASS new HashChangeEvent('eventType', { newURL: undefined }).newURL is ""
PASS new HashChangeEvent('eventType', { newURL: null }).newURL is "null"
PASS new HashChangeEvent('eventType', { newURL: false }).newURL is "false"
PASS new HashChangeEvent('eventType', { newURL: true }).newURL is "true"
PASS new HashChangeEvent('eventType', { newURL: 12345 }).newURL is "12345"
PASS new HashChangeEvent('eventType', { newURL: 18446744073709551615 }).newURL is "18446744073709552000"
PASS new HashChangeEvent('eventType', { newURL: NaN }).newURL is "NaN"
PASS new HashChangeEvent('eventType', { newURL: [] }).newURL is ""
PASS new HashChangeEvent('eventType', { newURL: [1, 2, 3] }).newURL is "1,2,3"
PASS new HashChangeEvent('eventType', { newURL: {doremi: 12345} }).newURL is "[object Object]"
PASS new HashChangeEvent('eventType', { newURL: {valueOf: function () { return 'doremi'; } } }).newURL is "[object Object]"
PASS new HashChangeEvent('eventType', { bubbles: true, cancelable: true, oldURL: 'doremi', newURL: 'andre' }).bubbles is true
PASS new HashChangeEvent('eventType', { bubbles: true, cancelable: true, oldURL: 'doremi', newURL: 'andre' }).cancelable is true
PASS new HashChangeEvent('eventType', { bubbles: true, cancelable: true, oldURL: 'doremi', newURL: 'andre' }).oldURL is "doremi"
PASS new HashChangeEvent('eventType', { bubbles: true, cancelable: true, oldURL: 'doremi', newURL: 'andre' }).newURL is "andre"
PASS successfullyParsed is true
TEST COMPLETE