This tests that when 'window.onerror' handler is called, 'window.event' is the corresponding ErrorEvent object.