| 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 part of unittest; |
| 6 |
| 5 /** | 7 /** |
| 6 * testcase.dart: this file is sourced by unittest.dart. It defines [TestCase] | 8 * testcase.dart: this file is sourced by unittest.dart. It defines [TestCase] |
| 7 * and assumes unittest defines the type [TestFunction]. | 9 * and assumes unittest defines the type [TestFunction]. |
| 8 */ | 10 */ |
| 9 | 11 |
| 10 /** Summarizes information about a single test case. */ | 12 /** Summarizes information about a single test case. */ |
| 11 | |
| 12 part of unittest; | |
| 13 | |
| 14 class TestCase { | 13 class TestCase { |
| 15 /** Identifier for this test. */ | 14 /** Identifier for this test. */ |
| 16 final int id; | 15 final int id; |
| 17 | 16 |
| 18 /** A description of what the test is specifying. */ | 17 /** A description of what the test is specifying. */ |
| 19 final String description; | 18 final String description; |
| 20 | 19 |
| 21 /** The setup function to call before the test, if any. */ | 20 /** The setup function to call before the test, if any. */ |
| 22 Function _setUp; | 21 Function _setUp; |
| 23 | 22 |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 } | 119 } |
| 121 } | 120 } |
| 122 | 121 |
| 123 void error(String messageText, [String stack = '']) { | 122 void error(String messageText, [String stack = '']) { |
| 124 result = ERROR; | 123 result = ERROR; |
| 125 message = messageText; | 124 message = messageText; |
| 126 stackTrace = stack; | 125 stackTrace = stack; |
| 127 _complete(); | 126 _complete(); |
| 128 } | 127 } |
| 129 } | 128 } |
| OLD | NEW |