tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

sync-no-progress.any.js (497B)


      1 // META: timeout=long
      2 test(t => {
      3  let xhr = new XMLHttpRequest();
      4  let loadEventFired = false;
      5  xhr.onprogress = t.unreached_func('progress event should not be fired');
      6  xhr.onload = () => {
      7    loadEventFired = true;
      8  };
      9  xhr.open('GET', 'resources/trickle.py?count=4&delay=150', false);
     10  xhr.send();
     11  // Check the load event as a sanity check that the test is working.
     12  assert_true(loadEventFired, 'load event should have fired');
     13 }, 'progress event should not be fired by sync XHR');