- fixed GH# 116: Wrong timezone parsing in DateTimeParse (fix by Matej Knopp)

This commit is contained in:
Guenter Obiltschnig
2013-03-06 07:50:02 +01:00
parent 3c7bae11fc
commit dc5c8c87da
2 changed files with 19 additions and 6 deletions

View File

@@ -1,7 +1,7 @@
//
// DateTimeParserTest.cpp
//
// $Id: //poco/1.4/Foundation/testsuite/src/DateTimeParserTest.cpp#4 $
// $Id: //poco/1.4/Foundation/testsuite/src/DateTimeParserTest.cpp#5 $
//
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
@@ -341,6 +341,15 @@ void DateTimeParserTest::testRFC1123()
assert (dt.minute() == 17);
assert (dt.second() == 30);
assert (tzd == -14400);
dt = DateTimeParser::parse(DateTimeFormat::RFC1123_FORMAT, "Sun, 20 Jul 1969 16:17:30 GMT+01:00", tzd);
assert (dt.year() == 1969);
assert (dt.month() == 7);
assert (dt.day() == 20);
assert (dt.hour() == 16);
assert (dt.minute() == 17);
assert (dt.second() == 30);
assert (tzd == 3600);
}