Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(206)

Unified Diff: webrtc/base/stringencode_unittest.cc

Issue 2718663005: Replace NULL with nullptr or null in webrtc/base/. (Closed)
Patch Set: Fixing Windows and formatting issues. Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/base/stringencode.cc ('k') | webrtc/base/stringutils.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/stringencode_unittest.cc
diff --git a/webrtc/base/stringencode_unittest.cc b/webrtc/base/stringencode_unittest.cc
index fbd7975a8edd056bd7f9b27735c3d9a1374064c5..60929f3aed2b08e04fa3bf951cc0d907d2588caf 100644
--- a/webrtc/base/stringencode_unittest.cc
+++ b/webrtc/base/stringencode_unittest.cc
@@ -21,18 +21,18 @@ TEST(Utf8EncodeTest, EncodeDecode) {
size_t encsize, enclen;
unsigned long decoded;
} kTests[] = {
- { "a ", 5, 1, 'a' },
- { "\x7F ", 5, 1, 0x7F },
- { "\xC2\x80 ", 5, 2, 0x80 },
- { "\xDF\xBF ", 5, 2, 0x7FF },
- { "\xE0\xA0\x80 ", 5, 3, 0x800 },
- { "\xEF\xBF\xBF ", 5, 3, 0xFFFF },
- { "\xF0\x90\x80\x80 ", 5, 4, 0x10000 },
- { "\xF0\x90\x80\x80 ", 3, 0, 0x10000 },
- { "\xF0\xF0\x80\x80 ", 5, 0, 0 },
- { "\xF0\x90\x80 ", 5, 0, 0 },
- { "\x90\x80\x80 ", 5, 0, 0 },
- { NULL, 0, 0 },
+ {"a ", 5, 1, 'a'},
+ {"\x7F ", 5, 1, 0x7F},
+ {"\xC2\x80 ", 5, 2, 0x80},
+ {"\xDF\xBF ", 5, 2, 0x7FF},
+ {"\xE0\xA0\x80 ", 5, 3, 0x800},
+ {"\xEF\xBF\xBF ", 5, 3, 0xFFFF},
+ {"\xF0\x90\x80\x80 ", 5, 4, 0x10000},
+ {"\xF0\x90\x80\x80 ", 3, 0, 0x10000},
+ {"\xF0\xF0\x80\x80 ", 5, 0, 0},
+ {"\xF0\x90\x80 ", 5, 0, 0},
+ {"\x90\x80\x80 ", 5, 0, 0},
+ {nullptr, 0, 0},
};
for (size_t i = 0; kTests[i].encoded; ++i) {
unsigned long val = 0;
@@ -248,7 +248,7 @@ TEST(TokenizeTest, CompareSubstrings) {
}
TEST(TokenizeTest, TokenizeAppend) {
- ASSERT_EQ(0ul, tokenize_append("A B C", ' ', NULL));
+ ASSERT_EQ(0ul, tokenize_append("A B C", ' ', nullptr));
std::vector<std::string> fields;
@@ -263,7 +263,7 @@ TEST(TokenizeTest, TokenizeAppend) {
}
TEST(TokenizeTest, TokenizeWithMarks) {
- ASSERT_EQ(0ul, tokenize("D \"A B", ' ', '(', ')', NULL));
+ ASSERT_EQ(0ul, tokenize("D \"A B", ' ', '(', ')', nullptr));
std::vector<std::string> fields;
tokenize("A B C", ' ', '"', '"', &fields);
« no previous file with comments | « webrtc/base/stringencode.cc ('k') | webrtc/base/stringutils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698