| OLD | NEW |
| 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 /** | 5 /** |
| 6 * A simple unit test library for running tests in a browser. | 6 * A simple unit test library for running tests in a browser. |
| 7 * | 7 * |
| 8 * Provides enhanced HTML output with collapsible group headers | 8 * Provides enhanced HTML output with collapsible group headers |
| 9 * and other at-a-glance information about the test results. | 9 * and other at-a-glance information about the test results. |
| 10 */ | 10 */ |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 228 | 228 |
| 229 addRowElement('${test_.id}', '${test_.result.toUpperCase()}', | 229 addRowElement('${test_.id}', '${test_.result.toUpperCase()}', |
| 230 '${test_.description}. ${_htmlEscape(test_.message)}'); | 230 '${test_.description}. ${_htmlEscape(test_.message)}'); |
| 231 | 231 |
| 232 if (test_.stackTrace != null) { | 232 if (test_.stackTrace != null) { |
| 233 addRowElement('', '', '<pre>${_htmlEscape(test_.stackTrace)}</pre>'); | 233 addRowElement('', '', '<pre>${_htmlEscape(test_.stackTrace)}</pre>'); |
| 234 } | 234 } |
| 235 } | 235 } |
| 236 | 236 |
| 237 | 237 |
| 238 static bool get _isIE() => document.window.navigator.userAgent.contains('MSIE'
); | 238 static bool get _isIE => document.window.navigator.userAgent.contains('MSIE'); |
| 239 | 239 |
| 240 String get _htmlTestCSS() => | 240 String get _htmlTestCSS => |
| 241 ''' | 241 ''' |
| 242 body{ | 242 body{ |
| 243 font-size: 14px; | 243 font-size: 14px; |
| 244 font-family: 'Open Sans', 'Lucida Sans Unicode', 'Lucida Grande', sans-serif
; | 244 font-family: 'Open Sans', 'Lucida Sans Unicode', 'Lucida Grande', sans-serif
; |
| 245 background: WhiteSmoke; | 245 background: WhiteSmoke; |
| 246 } | 246 } |
| 247 | 247 |
| 248 .unittest-group | 248 .unittest-group |
| 249 { | 249 { |
| 250 background: rgb(75,75,75); | 250 background: rgb(75,75,75); |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 .unittest-row-description | 361 .unittest-row-description |
| 362 { | 362 { |
| 363 } | 363 } |
| 364 | 364 |
| 365 '''; | 365 '''; |
| 366 } | 366 } |
| 367 | 367 |
| 368 void useHtmlEnhancedConfiguration([bool isLayoutTest = false]) { | 368 void useHtmlEnhancedConfiguration([bool isLayoutTest = false]) { |
| 369 configure(new HtmlEnhancedConfiguration(isLayoutTest)); | 369 configure(new HtmlEnhancedConfiguration(isLayoutTest)); |
| 370 } | 370 } |
| OLD | NEW |