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

Side by Side Diff: tests/corelib/date_time4_test.dart

Issue 12743005: Revert "Remove Expect from core library." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Reupload (first upload failed). Created 7 years, 9 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/corelib/date_time3_test.dart ('k') | tests/corelib/date_time5_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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 import "package:expect/expect.dart";
6
7 // Test fromString with 6 digits after the decimal point. 5 // Test fromString with 6 digits after the decimal point.
8 6
9 main() { 7 main() {
10 // We only support milliseconds. If the user supplies more data (the "51" 8 // We only support milliseconds. If the user supplies more data (the "51"
11 // here), we round. 9 // here), we round.
12 // If (eventually) we support more than just milliseconds this test could 10 // If (eventually) we support more than just milliseconds this test could
13 // fail. Please update the test in this case. 11 // fail. Please update the test in this case.
14 DateTime dt1 = DateTime.parse("1999-01-02 23:59:59.999519"); 12 DateTime dt1 = DateTime.parse("1999-01-02 23:59:59.999519");
15 Expect.equals(1999, dt1.year); 13 Expect.equals(1999, dt1.year);
16 Expect.equals(1, dt1.month); 14 Expect.equals(1, dt1.month);
(...skipping 26 matching lines...) Expand all
43 Expect.equals(2012, dt1.year); 41 Expect.equals(2012, dt1.year);
44 Expect.equals(3, dt1.month); 42 Expect.equals(3, dt1.month);
45 Expect.equals(30, dt1.day); 43 Expect.equals(30, dt1.day);
46 Expect.equals(4, dt1.hour); 44 Expect.equals(4, dt1.hour);
47 Expect.equals(28, dt1.minute); 45 Expect.equals(28, dt1.minute);
48 Expect.equals(13, dt1.second); 46 Expect.equals(13, dt1.second);
49 Expect.equals(752, dt1.millisecond); 47 Expect.equals(752, dt1.millisecond);
50 Expect.equals(true, dt1.isUtc); 48 Expect.equals(true, dt1.isUtc);
51 49
52 } 50 }
OLDNEW
« no previous file with comments | « tests/corelib/date_time3_test.dart ('k') | tests/corelib/date_time5_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698