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

Side by Side Diff: chrome/browser/safe_browsing/unverified_download_policy_unittest.cc

Issue 1658793002: Update chrome for new prefs location. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "chrome/browser/safe_browsing/unverified_download_policy.h" 5 #include "chrome/browser/safe_browsing/unverified_download_policy.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/callback_helpers.h" 9 #include "base/callback_helpers.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
11 #include "base/files/file_path.h" 11 #include "base/files/file_path.h"
12 #include "base/prefs/testing_pref_service.h"
13 #include "base/run_loop.h" 12 #include "base/run_loop.h"
14 #include "chrome/browser/safe_browsing/safe_browsing_service.h" 13 #include "chrome/browser/safe_browsing/safe_browsing_service.h"
15 #include "chrome/common/chrome_switches.h" 14 #include "chrome/common/chrome_switches.h"
16 #include "chrome/common/pref_names.h" 15 #include "chrome/common/pref_names.h"
17 #include "chrome/test/base/testing_browser_process.h" 16 #include "chrome/test/base/testing_browser_process.h"
18 #include "chrome/test/base/testing_profile_manager.h" 17 #include "chrome/test/base/testing_profile_manager.h"
18 #include "components/prefs/testing_pref_service.h"
19 #include "components/safe_browsing_db/test_database_manager.h" 19 #include "components/safe_browsing_db/test_database_manager.h"
20 #include "content/public/test/test_browser_thread_bundle.h" 20 #include "content/public/test/test_browser_thread_bundle.h"
21 #include "testing/gtest/include/gtest/gtest.h" 21 #include "testing/gtest/include/gtest/gtest.h"
22 #include "url/gurl.h" 22 #include "url/gurl.h"
23 23
24 namespace safe_browsing { 24 namespace safe_browsing {
25 25
26 namespace { 26 namespace {
27 27
28 class FakeDatabaseManager : public TestSafeBrowsingDatabaseManager { 28 class FakeDatabaseManager : public TestSafeBrowsingDatabaseManager {
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 219
220 CompletionCallback completion_callback; 220 CompletionCallback completion_callback;
221 CheckUnverifiedDownloadPolicy(GURL("http://supported.example.com/foo/bar"), 221 CheckUnverifiedDownloadPolicy(GURL("http://supported.example.com/foo/bar"),
222 test_file_path, test_extensions, 222 test_file_path, test_extensions,
223 completion_callback.GetCallback()); 223 completion_callback.GetCallback());
224 EXPECT_EQ(UnverifiedDownloadPolicy::ALLOWED, 224 EXPECT_EQ(UnverifiedDownloadPolicy::ALLOWED,
225 completion_callback.WaitForResult()); 225 completion_callback.WaitForResult());
226 } 226 }
227 227
228 } // namespace safe_browsing 228 } // namespace safe_browsing
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/ui_manager.cc ('k') | chrome/browser/search/contextual_search_policy_handler_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698