src/base/str.test.cc
/**
 * Test that a double can still be converted to int as long as it is below
 * the numerical limit + 1.
 */
Test that a double can still be converted to int as long as it is below
the numerical limit + 1.
Test that a double can still be converted to int as long as it is below the numerical limit + 1 .
TEST(StrTest, ToNumber8BitUnsignedLimit)
{
    uint8_t output;
    std::string input = "255.99";
    EXPECT_TRUE(to_number(input, output));
    EXPECT_EQ(255, output);
}
TEST ( StrTest , ToNumber8BitUnsignedLimit ) { uint8_t output ; std :: string input = " " ; EXPECT_TRUE ( to_number ( input , output ) ) ; EXPECT_EQ ( 255 , output ) ; }
Test that a double can still be converted to int as long as it is below
 the numerical limit + 1.
Test that a double can still be converted to int as long as it is below the numerical limit + 1 .