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

Unified Diff: third_party/WebKit/Source/platform/weborigin/DatabaseIdentifierTest.cpp

Issue 1548993002: Switch to standard integer types in base/strings/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
Index: third_party/WebKit/Source/platform/weborigin/DatabaseIdentifierTest.cpp
diff --git a/third_party/WebKit/Source/platform/weborigin/DatabaseIdentifierTest.cpp b/third_party/WebKit/Source/platform/weborigin/DatabaseIdentifierTest.cpp
index b82b096abd426ed8e621134cdc1a28cbc6ed8840..01bc1cf91af5a3d4b6af75331107abff7c597a70 100644
--- a/third_party/WebKit/Source/platform/weborigin/DatabaseIdentifierTest.cpp
+++ b/third_party/WebKit/Source/platform/weborigin/DatabaseIdentifierTest.cpp
@@ -59,7 +59,7 @@ TEST(DatabaseIdentifierTest, CreateIdentifierFromSecurityOrigin)
{"non-standard", "foobar.com", 0, "non-standard__0"},
};
- for (size_t i = 0; i < arraysize(cases); ++i) {
+ for (size_t i = 0; i < WTF_ARRAY_LENGTH(cases); ++i) {
RefPtr<SecurityOrigin> origin = SecurityOrigin::create(cases[i].protocol, cases[i].host, cases[i].port);
String identifier = createDatabaseIdentifierFromSecurityOrigin(origin.get());
EXPECT_EQ(cases[i].expectedIdentifier, identifier) << "test case " << origin->toString();
@@ -181,7 +181,7 @@ TEST(DatabaseIdentifierTest, CreateIdentifierAllHostChars)
{"x\x80x", "__0", false},
};
- for (size_t i = 0; i < arraysize(cases); ++i) {
+ for (size_t i = 0; i < WTF_ARRAY_LENGTH(cases); ++i) {
RefPtr<SecurityOrigin> origin = SecurityOrigin::create("http", cases[i].hostname, 80);
String identifier = createDatabaseIdentifierFromSecurityOrigin(origin.get());
EXPECT_EQ(cases[i].expected, identifier) << "test case " << i << ": \"" << cases[i].hostname << "\"";
@@ -218,7 +218,7 @@ TEST(DatabaseIdentifierTest, CreateSecurityOriginFromIdentifier)
{"http_escaped%3Dfun.com_0", "http", "escaped%3dfun.com", 0, "http://escaped%3dfun.com", false},
};
- for (size_t i = 0; i < arraysize(validCases); ++i) {
+ for (size_t i = 0; i < WTF_ARRAY_LENGTH(validCases); ++i) {
RefPtr<SecurityOrigin> origin = createSecurityOriginFromDatabaseIdentifier(validCases[i].identifier);
EXPECT_EQ(validCases[i].expectedProtocol, origin->protocol()) << "test case " << i;
EXPECT_EQ(validCases[i].expectedHost, origin->host()) << "test case " << i;
@@ -244,7 +244,7 @@ TEST(DatabaseIdentifierTest, CreateSecurityOriginFromIdentifier)
"http_not_canonical_escape%3d_0",
};
- for (size_t i = 0; i < arraysize(bogusIdentifiers); ++i) {
+ for (size_t i = 0; i < WTF_ARRAY_LENGTH(bogusIdentifiers); ++i) {
RefPtr<SecurityOrigin> origin = createSecurityOriginFromDatabaseIdentifier(bogusIdentifiers[i]);
EXPECT_EQ("null", origin->toString()) << "test case " << i;
EXPECT_EQ(true, origin->isUnique()) << "test case " << i;

Powered by Google App Engine
This is Rietveld 408576698