Ticket #836: basetests.diff

File basetests.diff, 1.1 KB (added by jinmei, 9 years ago)
  • src/lib/dns/tests/base32hex_unittest.cc

    diff --git a/src/lib/dns/tests/base32hex_unittest.cc b/src/lib/dns/tests/base32hex_unittest.cc
    index 253d310..50d8530 100644
    a b decodeCheck(const string& input_string, vector<uint8_t>& output, 
    6666            const string& expected)
    6767{
    6868    decodeBase32Hex(input_string, output);
    69     EXPECT_EQ(expected, string(&output[0], &output[0] + output.size()));
     69    EXPECT_EQ(expected, string(output.begin(), output.end()));
    7070}
    7171
    7272TEST_F(Base32HexTest, decode) {
  • src/lib/dns/tests/base64_unittest.cc

    diff --git a/src/lib/dns/tests/base64_unittest.cc b/src/lib/dns/tests/base64_unittest.cc
    index 7333793..fd20170 100644
    a b decodeCheck(const string& input_string, vector<uint8_t>& output, 
    5252            const string& expected)
    5353{
    5454    decodeBase64(input_string, output);
    55     EXPECT_EQ(expected, string(&output[0], &output[0] + output.size()));
     55    EXPECT_EQ(expected, string(output.begin(), output.end()));
    5656}
    5757
    5858TEST_F(Base64Test, decode) {