tor-browser

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

test_HeapAnalyses_deleteHeapSnapshot_02.js (505B)


      1 /* Any copyright is dedicated to the Public Domain.
      2   http://creativecommons.org/publicdomain/zero/1.0/ */
      3 "use strict";
      4 
      5 // Test deleteHeapSnapshot is a noop if the provided path matches no snapshot
      6 
      7 add_task(async function () {
      8  const client = new HeapAnalysesClient();
      9 
     10  let threw = false;
     11  try {
     12    await client.deleteHeapSnapshot("path-does-not-exist");
     13  } catch (_) {
     14    threw = true;
     15  }
     16  ok(threw, "deleteHeapSnapshot on non-existant path should throw an error");
     17 
     18  client.destroy();
     19 });