Skip to content

DateFormat cannot parse time zones #16801

Closed
@DartBot

Description

@DartBot

This issue was originally filed by [email protected]


What steps will reproduce the problem?
        test('> parseForIssueReport', () {
            final DateFormat rfc822Formatter = new DateFormat("EEE, dd MMM yyyy HH:mm:ss Z","en_US");
            final DateTime dt = rfc822Formatter.parse("Wed, 02 Oct 2002 15:00:00 +0230");

            expect(dt.timeZoneOffset.inMinutes, 150);
        }); // end of 'parseForIssueReport' test

What is the expected output? What do you see instead?
+230 should be 150 minutes!

What version of the product are you using? On what operating system?
Dart SDK 1.1.3 + intl 0.9.4

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-pkgUsed for miscellaneous pkg/ packages not associated with specific area- teams.closed-duplicateClosed in favor of an existing report

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions