chromium/chrome/test/data/beforeunload.html

<html>
  <head>
    <title>Loading...</title>
    <script>
      window.onbeforeunload = function(e) { return 'foo'; };
    </script>
  </head>
  <body>
    <p>Navigate to another page to trigger beforeunload handler.</p>
  </body>
</html>