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

Side by Side Diff: pkg/unittest/lib/unittest.dart

Issue 11361190: a === b -> identical(a, b) (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 8 years, 1 month 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 | « pkg/unittest/lib/src/core_matchers.dart ('k') | runtime/bin/builtin.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 /** 5 /**
6 * A library for writing dart unit tests. 6 * A library for writing dart unit tests.
7 * 7 *
8 * To import this library, use the pub package manager. 8 * To import this library, use the pub package manager.
9 * Create a pubspec.yaml file in your project and add 9 * Create a pubspec.yaml file in your project and add
10 * a dependency on unittest with the following lines: 10 * a dependency on unittest with the following lines:
(...skipping 820 matching lines...) Expand 10 before | Expand all | Expand 10 after
831 case FAIL: testsFailed_++; break; 831 case FAIL: testsFailed_++; break;
832 case ERROR: testsErrors_++; break; 832 case ERROR: testsErrors_++; break;
833 } 833 }
834 } 834 }
835 _config.onDone(testsPassed_, testsFailed_, testsErrors_, _tests, 835 _config.onDone(testsPassed_, testsFailed_, testsErrors_, _tests,
836 _uncaughtErrorMessage); 836 _uncaughtErrorMessage);
837 _initialized = false; 837 _initialized = false;
838 } 838 }
839 839
840 String _fullSpec(String spec) { 840 String _fullSpec(String spec) {
841 if (spec === null) return '$_currentGroup'; 841 if (spec == null) return '$_currentGroup';
842 return _currentGroup != '' ? '$_currentGroup$groupSep$spec' : spec; 842 return _currentGroup != '' ? '$_currentGroup$groupSep$spec' : spec;
843 } 843 }
844 844
845 void fail(String message) { 845 void fail(String message) {
846 throw new ExpectException(message); 846 throw new ExpectException(message);
847 } 847 }
848 848
849 /** 849 /**
850 * Lazily initializes the test library if not already initialized. 850 * Lazily initializes the test library if not already initialized.
851 */ 851 */
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
899 } 899 }
900 900
901 /** Enable a test by ID. */ 901 /** Enable a test by ID. */
902 void enableTest(int testId) => _setTestEnabledState(testId, true); 902 void enableTest(int testId) => _setTestEnabledState(testId, true);
903 903
904 /** Disable a test by ID. */ 904 /** Disable a test by ID. */
905 void disableTest(int testId) => _setTestEnabledState(testId, false); 905 void disableTest(int testId) => _setTestEnabledState(testId, false);
906 906
907 /** Signature for a test function. */ 907 /** Signature for a test function. */
908 typedef void TestFunction(); 908 typedef void TestFunction();
OLDNEW
« no previous file with comments | « pkg/unittest/lib/src/core_matchers.dart ('k') | runtime/bin/builtin.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698