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

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

Issue 10500016: Move test_browser_thread.h from content\test to content\public\test. This way we can enforce that i… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // This test creates a safebrowsing service using test safebrowsing database 5 // This test creates a safebrowsing service using test safebrowsing database
6 // and a test protocol manager. It is used to test logics in safebrowsing 6 // and a test protocol manager. It is used to test logics in safebrowsing
7 // service. 7 // service.
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "base/metrics/histogram.h" 12 #include "base/metrics/histogram.h"
13 #include "base/scoped_temp_dir.h" 13 #include "base/scoped_temp_dir.h"
14 #include "chrome/browser/browser_process.h" 14 #include "chrome/browser/browser_process.h"
15 #include "chrome/browser/prefs/pref_service.h" 15 #include "chrome/browser/prefs/pref_service.h"
16 #include "chrome/browser/prerender/prerender_manager.h" 16 #include "chrome/browser/prerender/prerender_manager.h"
17 #include "chrome/browser/profiles/profile.h" 17 #include "chrome/browser/profiles/profile.h"
18 #include "chrome/browser/safe_browsing/client_side_detection_service.h" 18 #include "chrome/browser/safe_browsing/client_side_detection_service.h"
19 #include "chrome/browser/safe_browsing/protocol_manager.h" 19 #include "chrome/browser/safe_browsing/protocol_manager.h"
20 #include "chrome/browser/safe_browsing/safe_browsing_database.h" 20 #include "chrome/browser/safe_browsing/safe_browsing_database.h"
21 #include "chrome/browser/safe_browsing/safe_browsing_service.h" 21 #include "chrome/browser/safe_browsing/safe_browsing_service.h"
22 #include "chrome/browser/safe_browsing/safe_browsing_util.h" 22 #include "chrome/browser/safe_browsing/safe_browsing_util.h"
23 #include "chrome/browser/ui/browser.h" 23 #include "chrome/browser/ui/browser.h"
24 #include "chrome/common/chrome_switches.h" 24 #include "chrome/common/chrome_switches.h"
25 #include "chrome/common/pref_names.h" 25 #include "chrome/common/pref_names.h"
26 #include "chrome/test/base/in_process_browser_test.h" 26 #include "chrome/test/base/in_process_browser_test.h"
27 #include "chrome/test/base/ui_test_utils.h" 27 #include "chrome/test/base/ui_test_utils.h"
28 #include "content/public/browser/web_contents.h" 28 #include "content/public/browser/web_contents.h"
29 #include "content/public/browser/web_contents_view.h" 29 #include "content/public/browser/web_contents_view.h"
30 #include "content/test/test_browser_thread.h" 30 #include "content/public/test/test_browser_thread.h"
31 #include "crypto/sha2.h" 31 #include "crypto/sha2.h"
32 #include "testing/gmock/include/gmock/gmock.h" 32 #include "testing/gmock/include/gmock/gmock.h"
33 33
34 using base::Histogram; 34 using base::Histogram;
35 using base::StatisticsRecorder; 35 using base::StatisticsRecorder;
36 using content::BrowserThread; 36 using content::BrowserThread;
37 using content::InterstitialPage; 37 using content::InterstitialPage;
38 using content::WebContents; 38 using content::WebContents;
39 using ::testing::_; 39 using ::testing::_;
40 using ::testing::Mock; 40 using ::testing::Mock;
(...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after
759 759
760 // Delete the Profile. SBS stops again. 760 // Delete the Profile. SBS stops again.
761 pref_service2 = NULL; 761 pref_service2 = NULL;
762 profile2.reset(); 762 profile2.reset();
763 WaitForIOThread(); 763 WaitForIOThread();
764 EXPECT_FALSE(sb_service->enabled()); 764 EXPECT_FALSE(sb_service->enabled());
765 EXPECT_FALSE(csd_service->enabled()); 765 EXPECT_FALSE(csd_service->enabled());
766 } 766 }
767 767
768 } // namespace 768 } // namespace
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/safe_browsing_database_unittest.cc ('k') | chrome/browser/safe_browsing/safe_browsing_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698