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

Unified Diff: net/http/http_content_disposition_unittest.cc

Issue 662553002: Convert ARRAYSIZE_UNSAFE -> arraysize in net/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 | « net/http/http_cache_transaction.cc ('k') | net/http/http_network_transaction_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_content_disposition_unittest.cc
diff --git a/net/http/http_content_disposition_unittest.cc b/net/http/http_content_disposition_unittest.cc
index 43fef9dd0eab1d0ca4f64713d9e8848380dbd3e6..e617c6ca466984dff7edada896564184ef0e9e14 100644
--- a/net/http/http_content_disposition_unittest.cc
+++ b/net/http/http_content_disposition_unittest.cc
@@ -195,7 +195,7 @@ TEST(HttpContentDispositionTest, Filename) {
{"attachment; foobar=x; filename=\"foo.html\"", "",
L"foo.html"},
};
- for (size_t i = 0; i < ARRAYSIZE_UNSAFE(tests); ++i) {
+ for (size_t i = 0; i < arraysize(tests); ++i) {
HttpContentDisposition header(tests[i].header, tests[i].referrer_charset);
EXPECT_EQ(tests[i].expected,
base::UTF8ToWide(header.filename()))
@@ -503,7 +503,7 @@ TEST(HttpContentDispositionTest, tc2231) {
// TODO(abarth): http://greenbytes.de/tech/tc2231/#attrfc2047token
// TODO(abarth): http://greenbytes.de/tech/tc2231/#attrfc2047quoted
};
- for (size_t i = 0; i < ARRAYSIZE_UNSAFE(tests); ++i) {
+ for (size_t i = 0; i < arraysize(tests); ++i) {
HttpContentDisposition header(tests[i].header, std::string());
EXPECT_EQ(tests[i].expected_type, header.type())
<< "Failed on input: " << tests[i].header;
@@ -576,7 +576,7 @@ TEST(HttpContentDispositionTest, ParseResult) {
HttpContentDisposition::HAS_NAME },
};
- for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kTestCases); ++i) {
+ for (size_t i = 0; i < arraysize(kTestCases); ++i) {
const ParseResultTestCase& test_case = kTestCases[i];
HttpContentDisposition content_disposition(test_case.header, "utf-8");
int result = content_disposition.parse_result_flags();
« no previous file with comments | « net/http/http_cache_transaction.cc ('k') | net/http/http_network_transaction_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698