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

Side by Side Diff: lib/src/test_case.dart

Issue 845153003: Bumped matcher version constraint (Closed) Base URL: https://github.com/dart-lang/unittest.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « lib/html_enhanced_config.dart ('k') | pubspec.yaml » ('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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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; 5 part of unittest;
6 6
7 /// Represents the state for an individual unit test. 7 /// Represents the state for an individual unit test.
8 /// 8 ///
9 /// Create by calling [test] or [solo_test]. 9 /// Create by calling [test] or [solo_test].
10 class TestCase { 10 class TestCase {
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 DateTime _startTime; 48 DateTime _startTime;
49 DateTime get startTime => _startTime; 49 DateTime get startTime => _startTime;
50 50
51 Duration _runningTime; 51 Duration _runningTime;
52 Duration get runningTime => _runningTime; 52 Duration get runningTime => _runningTime;
53 53
54 bool _enabled = true; 54 bool _enabled = true;
55 55
56 bool get enabled => _enabled; 56 bool get enabled => _enabled;
57 57
58 bool _doneTeardown = false;
59
60 Completer _testComplete; 58 Completer _testComplete;
61 59
62 TestCase._internal(this.id, this.description, this._testFunction) 60 TestCase._internal(this.id, this.description, this._testFunction)
63 : currentGroup = _environment.currentContext.fullName, 61 : currentGroup = _environment.currentContext.fullName,
64 _setUp = _environment.currentContext.testSetup, 62 _setUp = _environment.currentContext.testSetup,
65 _tearDown = _environment.currentContext.testTeardown; 63 _tearDown = _environment.currentContext.testTeardown;
66 64
67 bool get isComplete => !enabled || result != null; 65 bool get isComplete => !enabled || result != null;
68 66
69 Function _errorHandler(String stage) => (e, stack) { 67 Function _errorHandler(String stage) => (e, stack) {
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 } 181 }
184 182
185 void _markCallbackComplete() { 183 void _markCallbackComplete() {
186 if (--_callbackFunctionsOutstanding == 0 && !isComplete) { 184 if (--_callbackFunctionsOutstanding == 0 && !isComplete) {
187 _pass(); 185 _pass();
188 } 186 }
189 } 187 }
190 188
191 String toString() => _result != null ? "$description: $result" : description; 189 String toString() => _result != null ? "$description: $result" : description;
192 } 190 }
OLDNEW
« no previous file with comments | « lib/html_enhanced_config.dart ('k') | pubspec.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698