browser_jsterm_editor_execute.js (734B)
1 /* Any copyright is dedicated to the Public Domain. 2 * http://creativecommons.org/publicdomain/zero/1.0/ */ 3 4 // Test that user input is not cleared when 'devtools.webconsole.input.editor' 5 // is set to true. 6 // See https://bugzilla.mozilla.org/show_bug.cgi?id=1519313 7 8 "use strict"; 9 10 const TEST_URI = 11 "data:text/html;charset=utf-8,<!DOCTYPE html>Web Console test for bug 1519313"; 12 13 add_task(async function () { 14 await pushPref("devtools.webconsole.input.editor", true); 15 const hud = await openNewTabAndConsole(TEST_URI); 16 17 const expression = `x = 10`; 18 setInputValue(hud, expression); 19 await executeAndWaitForResultMessage(hud, undefined, ""); 20 is(getInputValue(hud), expression, "input line is not cleared after submit"); 21 });