blob: ab82695b4b0d61cf25c70e020548f068742b233d [file] [log] [blame]
A couple of tests to ensure that adding a stop with an invalid color to a gradient throws exceptions normally, but not in dashboard.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Ensure exceptions are thrown in normal pages
PASS gradient.addColorStop(1, 'rgb(NaN%, NaN%, NaN%)') threw exception Error: SyntaxError: DOM Exception 12.
PASS gradient.addColorStop(1, 'rgb(NaN%, NaN%, NaN%)') threw exception Error: SyntaxError: DOM Exception 12.
Switching to dashboard compatibility mode. Invalid color strings should no longer cause an exception.
PASS gradient.addColorStop(1, 'rgb(NaN%, NaN%, NaN%)') is undefined.
PASS gradient.addColorStop(1, 'rgb(NaN%, NaN%, NaN%)') is undefined.
PASS successfullyParsed is true
TEST COMPLETE