Remove an unnecessary element.
Use window.onerror instead of window.addEventListener('error').

I believe the spec actually supports the latter now, but that is not the main goal of this test.
Use assert_equals for better error messages.