blob: 1e92755d8bf659f304c8c9d10de3da65e64cff83 [file] [log] [blame]
Test that WebKitMutationObserver.observe throws exceptions appropriately
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS observer.observe() threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': 1 argument required, but only 0 present..
PASS observer.observe(null) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': parameter 1 is not of type 'Node'..
PASS observer.observe(undefined) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': parameter 1 is not of type 'Node'..
PASS observer.observe(document.body) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true..
PASS observer.observe(document.body, null) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true..
PASS observer.observe(document.body, undefined) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true..
PASS observer.observe(null, {attributes: true}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': parameter 1 is not of type 'Node'..
PASS observer.observe(undefined, {attributes: true}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': parameter 1 is not of type 'Node'..
PASS observer.observe(document.body, {subtree: true}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true..
PASS observer.observe(document.body, {attributes: false, attributeOldValue: true}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object may only set 'attributeOldValue' to true when 'attributes' is true or not present..
PASS observer.observe(document.body, {attributes: false, attributeFilter: ["id"]}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object may only set 'attributeFilter' when 'attributes' is true or not present..
PASS observer.observe(document.body, {attributes: false, attributeOldValue: false}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true..
PASS observer.observe(document.body, {characterData: false, characterDataOldValue: true}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object may only set 'characterDataOldValue' to true when 'characterData' is true or not present..
PASS observer.observe(document.body, {characterData: false, characterDataOldValue: false}) threw exception TypeError: Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true..
PASS successfullyParsed is true
TEST COMPLETE