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

Unified Diff: tests/standalone/io/http_headers_test.dart

Issue 10411057: Deprecate use of timezones. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix code using old api. Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: tests/standalone/io/http_headers_test.dart
diff --git a/tests/standalone/io/http_headers_test.dart b/tests/standalone/io/http_headers_test.dart
index 137abe5c9d8cc63e8461ebb2ac44f58185c5b324..c0846cfca3b4a7b8a66a44516316cdacc6915a6c 100644
--- a/tests/standalone/io/http_headers_test.dart
+++ b/tests/standalone/io/http_headers_test.dart
@@ -50,11 +50,9 @@ void testMultiValue() {
}
void testDate() {
- Date date1 = new Date.withTimeZone(
- 1999, Date.JUN, 11, 18, 46, 53, 0, new TimeZone.utc());
+ Date date1 = new Date(1999, Date.JUN, 11, 18, 46, 53, 0, isUtc: true);
String httpDate1 = "Fri, 11 Jun 1999 18:46:53 GMT";
- Date date2 = new Date.withTimeZone(
- 2000, Date.AUG, 16, 12, 34, 56, 0, new TimeZone.utc());
+ Date date2 = new Date(2000, Date.AUG, 16, 12, 34, 56, 0, isUtc: true);
String httpDate2 = "Wed, 16 Aug 2000 12:34:56 GMT";
_HttpHeaders headers = new _HttpHeaders();
@@ -78,11 +76,9 @@ void testDate() {
}
void testExpires() {
- Date date1 = new Date.withTimeZone(
- 1999, Date.JUN, 11, 18, 46, 53, 0, new TimeZone.utc());
+ Date date1 = new Date(1999, Date.JUN, 11, 18, 46, 53, 0, isUtc: true);
String httpDate1 = "Fri, 11 Jun 1999 18:46:53 GMT";
- Date date2 = new Date.withTimeZone(
- 2000, Date.AUG, 16, 12, 34, 56, 0, new TimeZone.utc());
+ Date date2 = new Date(2000, Date.AUG, 16, 12, 34, 56, 0, isUtc: true);
String httpDate2 = "Wed, 16 Aug 2000 12:34:56 GMT";
_HttpHeaders headers = new _HttpHeaders();

Powered by Google App Engine
This is Rietveld 408576698