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

Side by Side Diff: tests/utils/test_utils.dart

Issue 10170040: test rename overhaul: step 11 - tests/utils (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 7 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
« no previous file with comments | « tests/utils/test_config.dart ('k') | tests/utils/uri_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #library('test_utils'); 5 #library('test_utils');
6 6
7 /** 7 /**
8 * Removes eight spaces of leading indentation from a multiline string. 8 * Removes eight spaces of leading indentation from a multiline string.
9 * 9 *
10 * Note that this is very sensitive to how the literals are styled. They should 10 * Note that this is very sensitive to how the literals are styled. They should
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 String indentLiteral(String text) { 44 String indentLiteral(String text) {
45 var lines = text.split('\n'); 45 var lines = text.split('\n');
46 if (lines.length <= 1) return text; 46 if (lines.length <= 1) return text;
47 47
48 for (var i = 0; i < lines.length; i++) { 48 for (var i = 0; i < lines.length; i++) {
49 lines[i] = " ${lines[i]}"; 49 lines[i] = " ${lines[i]}";
50 } 50 }
51 51
52 return Strings.join(lines, "\n"); 52 return Strings.join(lines, "\n");
53 } 53 }
OLDNEW
« no previous file with comments | « tests/utils/test_config.dart ('k') | tests/utils/uri_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698