tor-browser

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

browser_jsterm_autocomplete_in_chrome_tab.js (713B)


      1 /* Any copyright is dedicated to the Public Domain.
      2 * http://creativecommons.org/publicdomain/zero/1.0/ */
      3 
      4 // Tests that code completion works properly in chrome tabs, like about:config.
      5 
      6 "use strict";
      7 
      8 add_task(async function () {
      9  const hud = await openNewTabAndConsole("about:config");
     10  ok(hud, "we have a console");
     11  ok(hud.iframeWindow, "we have the console UI window");
     12 
     13  const { jsterm } = hud;
     14  ok(jsterm, "we have a jsterm");
     15  ok(hud.ui.outputNode, "we have an output node");
     16 
     17  // Test typing 'docu'.
     18  await setInputValueForAutocompletion(hud, "docu");
     19  checkInputCompletionValue(hud, "ment", "'docu' completion");
     20 
     21  info("Close autocomplete popup");
     22  await closeAutocompletePopup(hud);
     23 });