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

Unified Diff: tools/json_schema_compiler/test/simple_api_unittest.cc

Issue 383263005: Remove more CreateIntegerValue calls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: s/SetBoolean/SetInteger Created 6 years, 5 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 | « tools/json_schema_compiler/test/objects_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/json_schema_compiler/test/simple_api_unittest.cc
diff --git a/tools/json_schema_compiler/test/simple_api_unittest.cc b/tools/json_schema_compiler/test/simple_api_unittest.cc
index f34b9fc258201e02554b59bebe55119e846f29ea..6802febbbcdd9ba7e988c89a20fb9b32e633b737 100644
--- a/tools/json_schema_compiler/test/simple_api_unittest.cc
+++ b/tools/json_schema_compiler/test/simple_api_unittest.cc
@@ -14,8 +14,7 @@ static scoped_ptr<base::DictionaryValue> CreateTestTypeDictionary() {
scoped_ptr<base::DictionaryValue> value(new base::DictionaryValue());
value->SetWithoutPathExpansion("number",
base::Value::CreateDoubleValue(1.1));
- value->SetWithoutPathExpansion("integer",
- base::Value::CreateIntegerValue(4));
+ value->SetWithoutPathExpansion("integer", new base::FundamentalValue(4));
value->SetWithoutPathExpansion("string",
base::Value::CreateStringValue("bling"));
value->SetWithoutPathExpansion("boolean",
@@ -28,13 +27,13 @@ static scoped_ptr<base::DictionaryValue> CreateTestTypeDictionary() {
TEST(JsonSchemaCompilerSimpleTest, IncrementIntegerResultCreate) {
scoped_ptr<base::ListValue> results = IncrementInteger::Results::Create(5);
base::ListValue expected;
- expected.Append(base::Value::CreateIntegerValue(5));
+ expected.Append(new base::FundamentalValue(5));
EXPECT_TRUE(results->Equals(&expected));
}
TEST(JsonSchemaCompilerSimpleTest, IncrementIntegerParamsCreate) {
scoped_ptr<base::ListValue> params_value(new base::ListValue());
- params_value->Append(base::Value::CreateIntegerValue(6));
+ params_value->Append(new base::FundamentalValue(6));
scoped_ptr<IncrementInteger::Params> params(
IncrementInteger::Params::Create(*params_value));
EXPECT_TRUE(params.get());
@@ -91,7 +90,7 @@ TEST(JsonSchemaCompilerSimpleTest, OptionalParamsTakingNull) {
TEST(JsonSchemaCompilerSimpleTest, OptionalStringParamsWrongType) {
{
scoped_ptr<base::ListValue> params_value(new base::ListValue());
- params_value->Append(base::Value::CreateIntegerValue(5));
+ params_value->Append(new base::FundamentalValue(5));
scoped_ptr<OptionalString::Params> params(
OptionalString::Params::Create(*params_value));
EXPECT_FALSE(params.get());
@@ -154,7 +153,7 @@ TEST(JsonSchemaCompilerSimpleTest, OnIntegerFiredCreate) {
{
scoped_ptr<base::ListValue> results(OnIntegerFired::Create(5));
base::ListValue expected;
- expected.Append(base::Value::CreateIntegerValue(5));
+ expected.Append(new base::FundamentalValue(5));
EXPECT_TRUE(results->Equals(&expected));
}
}
« no previous file with comments | « tools/json_schema_compiler/test/objects_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698