Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(123)

Side by Side Diff: LayoutTests/http/tests/inspector-protocol/inspector-protocol-test.js

Issue 172593003: DevTools: [CSS] Add CSS.editRangeInStyleSheetText() to the protocol (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix glitch Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Samsung Electronics. All rights reserved. 2 * Copyright (C) 2012 Samsung Electronics. All rights reserved.
3 * Copyright (C) 2013 Google Inc. All rights reserved. 3 * Copyright (C) 2013 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 * @param {string} scriptName 239 * @param {string} scriptName
240 */ 240 */
241 InspectorTest.importScript = function(scriptName) 241 InspectorTest.importScript = function(scriptName)
242 { 242 {
243 var xhr = new XMLHttpRequest(); 243 var xhr = new XMLHttpRequest();
244 xhr.open("GET", scriptName, false); 244 xhr.open("GET", scriptName, false);
245 xhr.send(null); 245 xhr.send(null);
246 window.eval(xhr.responseText + "\n//@ sourceURL=" + scriptName); 246 window.eval(xhr.responseText + "\n//@ sourceURL=" + scriptName);
247 } 247 }
248 248
249 InspectorTest.runTestSuite = function(testSuite)
250 {
251 function nextTest()
252 {
253 if (!testSuite.length) {
254 InspectorTest.completeTest();
255 return;
256 }
257 var fun = testSuite.shift();
258 InspectorTest.log("\nRunning test: " + fun.name);
259 fun.call(null, nextTest);
260 }
261
262 nextTest();
263 }
264
249 }; 265 };
250 266
251 var outputElement; 267 var outputElement;
252 268
253 /** 269 /**
254 * Logs message to process stdout via alert (hopefully implemented with immediat e flush). 270 * Logs message to process stdout via alert (hopefully implemented with immediat e flush).
255 * @param {string} text 271 * @param {string} text
256 */ 272 */
257 function debugLog(text) 273 function debugLog(text)
258 { 274 {
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
330 initializers += "(" + window[symbol].toString() + ")();\n"; 346 initializers += "(" + window[symbol].toString() + ")();\n";
331 } 347 }
332 inspectorFrontend.postMessage(initializers + "(" + testFunction.toSt ring() +")();", "*"); 348 inspectorFrontend.postMessage(initializers + "(" + testFunction.toSt ring() +")();", "*");
333 return; 349 return;
334 } 350 }
335 // Kill waiting process if failed to send. 351 // Kill waiting process if failed to send.
336 alert("Failed to send test function"); 352 alert("Failed to send test function");
337 testRunner.notifyDone(); 353 testRunner.notifyDone();
338 }); 354 });
339 } 355 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698