https://github.com/web-platform-tests/wpt
Raw File
Tip revision: d56e1a8e1d3a6661b4c0ba56b67d48338426e3c9 authored by Ms2ger on 02 October 2018, 12:50:48 UTC
Refactor drawimage_svg_image_1.html.
Tip revision: d56e1a8
eventsource-onmessage.htm
<!DOCTYPE html>
<html>
  <head>
    <title>EventSource: onmessage</title>
    <script src="/resources/testharness.js"></script>
    <script src="/resources/testharnessreport.js"></script>
  </head>
  <body>
    <div id="log"></div>
    <script>
      var test = async_test()
      test.step(function() {
        var source = new EventSource("resources/message.py")
        source.onmessage = function(e) {
          test.step(function() {
            assert_equals("data", e.data)
            source.close()
          })
          test.done()
        }
      })
    </script>
  </body>
</html>

back to top