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

Unified Diff: LayoutTests/inspector/editor/highlighter-basics.html

Issue 22638008: DevTools: Use CodeMirror modes instead of highlight tokenizers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: address comments Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/inspector/editor/highlighter-basics-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/inspector/editor/highlighter-basics.html
diff --git a/LayoutTests/inspector/editor/highlighter-basics.html b/LayoutTests/inspector/editor/highlighter-basics.html
deleted file mode 100644
index b344728f6f945426f1dac3de22eeef62ff442b64..0000000000000000000000000000000000000000
--- a/LayoutTests/inspector/editor/highlighter-basics.html
+++ /dev/null
@@ -1,66 +0,0 @@
-<html>
-<head>
-<script src="../../http/tests/inspector/inspector-test.js"></script>
-<script src="highlighter-test.js"></script>
-<script>
-
-function test()
-{
- var src = "/**\n";
- for (var i = 1; i < 9; ++i) {
- src += " * line #" + i + "\n";
- }
- src += " * var a = new A(); //*/\n";
- src += "some text\n";
-
- var textModel = new WebInspector.TextEditorModel();
- textModel.setText(src);
-
- var highlighter = new WebInspector.TextEditorHighlighter(textModel, function() {});
- highlighter.mimeType = "text/javascript";
- highlighter.highlightChunkLimit = Number.MAX_VALUE; // Synchronous.
-
- function dumpTextModel(msg) {
- InspectorTest.addResult("\n" + msg);
- InspectorTest.dumpTextModel(textModel);
- }
-
- highlighter.highlight(5);
- dumpTextModel("After highlighting 5 lines");
-
- highlighter.highlight(textModel.linesCount);
- dumpTextModel("After highlighting all lines");
-
- var range = new WebInspector.TextRange(3, 0, 6, 0);
- var newRange = textModel.editRange(range, src);
- dumpTextModel("After changing text model, but before updating highlights");
-
- highlighter.updateHighlight(newRange.startLine, newRange.endLine + 1);
- dumpTextModel("After updating highlights");
-
- highlighter.highlight(textModel.linesCount, true);
- dumpTextModel("After highlighting up to the end");
-
- var range = new WebInspector.TextRange(0, 0, 0, textModel.lineLength(0));
- var newRange = textModel.editRange(range, "foo /* comment */");
- highlighter.updateHighlight(0, 5);
- dumpTextModel("After changing the first line, and updating the highlights for the first 5 lines");
-
- var range = new WebInspector.TextRange(0, textModel.lineLength(0), 0, textModel.lineLength(0));
- var newRange = textModel.editRange(range, " /*");
- highlighter.updateHighlight(0, 2);
- dumpTextModel("Again change the first line, but update only first 2 lines (invalidate update for the lines below)");
-
- InspectorTest.completeTest();
-}
-
-</script>
-</head>
-
-<body onload="runTest()">
-<p>
-This test checks highlighter correctness.
-</p>
-
-</body>
-</html>
« no previous file with comments | « no previous file | LayoutTests/inspector/editor/highlighter-basics-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698