test-exception-stackframe.html 1015 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <!DOCTYPE HTML>
  2. <html dir="ltr" lang="en">
  3. <head>
  4. <meta charset="utf8">
  5. <!--
  6. - Any copyright is dedicated to the Public Domain.
  7. - http://creativecommons.org/publicdomain/zero/1.0/
  8. -->
  9. <title>Test for bug 1184172 - stacktraces for exceptions</title>
  10. <script>
  11. function firstCall() {
  12. secondCall();
  13. }
  14. // Check anonymous functions
  15. var secondCall = function () {
  16. thirdCall();
  17. }
  18. function thirdCall() {
  19. nonExistingMethodCall();
  20. }
  21. function domAPI() {
  22. document.querySelector("buggy;selector");
  23. }
  24. function domException() {
  25. throw new DOMException("DOMException");
  26. }
  27. window.addEventListener("load", firstCall);
  28. window.addEventListener("load", function onLoadDomAPI() {
  29. domAPI();
  30. });
  31. window.addEventListener("load", function onLoadDomException() {
  32. domException();
  33. });
  34. </script>
  35. </head>
  36. <body>
  37. <p>Hello world!</p>
  38. </body>
  39. </html>