Skip to content

Add tests to format-test.cc #1498

Closed
Closed
@planet36

Description

Both format("{:#.0f}", 0.01) and format("{:#.0f}", 0.5) should return "0." (like std::ostringstream does), but they return "0" and "0..", respectively

Please add some tests to test-format.cc like the following:

EXPECT_EQ("0.", format("{:#.0f}", 0.01));
EXPECT_EQ("0.", format("{:#.0f}", 0.5));

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions