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

Unified Diff: components/policy/core/common/schema_unittest.cc

Issue 658993002: Convert ARRAYSIZE_UNSAFE -> arraysize in components/. (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 | « components/policy/core/common/schema.cc ('k') | components/query_parser/query_parser_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/policy/core/common/schema_unittest.cc
diff --git a/components/policy/core/common/schema_unittest.cc b/components/policy/core/common/schema_unittest.cc
index 766c6d9cb9b858abe4c98a8d1f54ee3a0025128b..db1490cecc253569a42b05e25808542b4bf58be1 100644
--- a/components/policy/core/common/schema_unittest.cc
+++ b/components/policy/core/common/schema_unittest.cc
@@ -410,7 +410,7 @@ TEST(SchemaTest, ValidSchema) {
{ "StringWithPattern", base::Value::TYPE_STRING },
};
Schema::Iterator it = schema.GetPropertiesIterator();
- for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kExpectedProperties); ++i) {
+ for (size_t i = 0; i < arraysize(kExpectedProperties); ++i) {
ASSERT_FALSE(it.IsAtEnd());
EXPECT_STREQ(kExpectedProperties[i].expected_key, it.key());
ASSERT_TRUE(it.schema().valid());
@@ -473,7 +473,7 @@ TEST(SchemaTest, Lookups) {
{ "abab", base::Value::TYPE_STRING },
{ "bb", base::Value::TYPE_NULL },
};
- for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kExpectedKeys); ++i) {
+ for (size_t i = 0; i < arraysize(kExpectedKeys); ++i) {
Schema sub = schema.GetKnownProperty(kExpectedKeys[i].expected_key);
ASSERT_TRUE(sub.valid());
EXPECT_EQ(kExpectedKeys[i].expected_type, sub.type());
@@ -559,7 +559,7 @@ TEST(SchemaTest, Wrap) {
};
Schema::Iterator it = schema.GetPropertiesIterator();
- for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kExpectedProperties); ++i) {
+ for (size_t i = 0; i < arraysize(kExpectedProperties); ++i) {
ASSERT_FALSE(it.IsAtEnd());
EXPECT_STREQ(kExpectedProperties[i].key, it.key());
Schema sub = it.schema();
« no previous file with comments | « components/policy/core/common/schema.cc ('k') | components/query_parser/query_parser_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698