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

Side by Side Diff: chrome/browser/supervised_user/supervised_user_browsertest.cc

Issue 2476493003: Remove FundamentalValue
Patch Set: Fix Created 4 years, 1 month 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <utility> 5 #include <utility>
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "base/values.h" 10 #include "base/values.h"
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 class SupervisedUserBlockModeTest : public SupervisedUserTest { 155 class SupervisedUserBlockModeTest : public SupervisedUserTest {
156 public: 156 public:
157 void SetUpOnMainThread() override { 157 void SetUpOnMainThread() override {
158 SupervisedUserTest::SetUpOnMainThread(); 158 SupervisedUserTest::SetUpOnMainThread();
159 159
160 Profile* profile = browser()->profile(); 160 Profile* profile = browser()->profile();
161 SupervisedUserSettingsService* supervised_user_settings_service = 161 SupervisedUserSettingsService* supervised_user_settings_service =
162 SupervisedUserSettingsServiceFactory::GetForProfile(profile); 162 SupervisedUserSettingsServiceFactory::GetForProfile(profile);
163 supervised_user_settings_service->SetLocalSetting( 163 supervised_user_settings_service->SetLocalSetting(
164 supervised_users::kContentPackDefaultFilteringBehavior, 164 supervised_users::kContentPackDefaultFilteringBehavior,
165 base::MakeUnique<base::FundamentalValue>( 165 base::MakeUnique<base::Value>(
166 SupervisedUserURLFilter::BLOCK)); 166 SupervisedUserURLFilter::BLOCK));
167 } 167 }
168 }; 168 };
169 169
170 class MockTabStripModelObserver : public TabStripModelObserver { 170 class MockTabStripModelObserver : public TabStripModelObserver {
171 public: 171 public:
172 explicit MockTabStripModelObserver(TabStripModel* tab_strip) 172 explicit MockTabStripModelObserver(TabStripModel* tab_strip)
173 : tab_strip_(tab_strip) { 173 : tab_strip_(tab_strip) {
174 tab_strip_->AddObserver(this); 174 tab_strip_->AddObserver(this);
175 } 175 }
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 scoped_refptr<SupervisedUserURLFilter> filter = 360 scoped_refptr<SupervisedUserURLFilter> filter =
361 supervised_user_service_->GetURLFilterForUIThread(); 361 supervised_user_service_->GetURLFilterForUIThread();
362 EXPECT_EQ(SupervisedUserURLFilter::ALLOW, 362 EXPECT_EQ(SupervisedUserURLFilter::ALLOW,
363 filter->GetFilteringBehaviorForURL(test_url.GetWithEmptyPath())); 363 filter->GetFilteringBehaviorForURL(test_url.GetWithEmptyPath()));
364 364
365 observer.Wait(); 365 observer.Wait();
366 EXPECT_EQ(test_url, web_contents->GetURL()); 366 EXPECT_EQ(test_url, web_contents->GetURL());
367 } 367 }
368 368
369 } // namespace 369 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698