Index: components/ntp_snippets/remote/ntp_snippets_fetcher_unittest.cc |
diff --git a/components/ntp_snippets/remote/ntp_snippets_fetcher_unittest.cc b/components/ntp_snippets/remote/ntp_snippets_fetcher_unittest.cc |
index a188e3c5aef9a57a474d79fa4cd1c363bc6409ba..dedc24dd9edb7cf16a1b17fde375d8c3071fe01a 100644 |
--- a/components/ntp_snippets/remote/ntp_snippets_fetcher_unittest.cc |
+++ b/components/ntp_snippets/remote/ntp_snippets_fetcher_unittest.cc |
@@ -174,10 +174,11 @@ void ParseJson( |
const ntp_snippets::NTPSnippetsFetcher::ErrorCallback& error_callback) { |
base::JSONReader json_reader; |
std::unique_ptr<base::Value> value = json_reader.ReadToValue(json); |
- if (value) |
+ if (value) { |
success_callback.Run(std::move(value)); |
- else |
+ } else { |
error_callback.Run(json_reader.GetErrorMessage()); |
+ } |
} |
void ParseJsonDelayed( |
@@ -247,8 +248,9 @@ class NTPSnippetsFetcherTest : public testing::Test { |
} |
void InitFakeURLFetcherFactory() { |
- if (fake_url_fetcher_factory_) |
+ if (fake_url_fetcher_factory_) { |
return; |
+ } |
// Instantiation of factory automatically sets itself as URLFetcher's |
// factory. |
fake_url_fetcher_factory_.reset(new net::FakeURLFetcherFactory( |
@@ -411,8 +413,9 @@ TEST_F(NTPSnippetsFetcherTest, BuildRequestExcludedIds) { |
NTPSnippetsFetcher::RequestBuilder builder; |
builder.params = test_params(); |
builder.params.interactive_request = false; |
- for (int i = 0; i < 200; ++i) |
+ for (int i = 0; i < 200; ++i) { |
builder.params.excluded_ids.insert(base::StringPrintf("%03d", i)); |
+ } |
builder.only_return_personalized_results = false; |
builder.user_class = "ACTIVE_NTP_USER"; |