OLD | NEW |
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 #include "base/bind.h" | 5 #include "base/bind.h" |
6 #include "base/files/file_path.h" | 6 #include "base/files/file_path.h" |
| 7 #include "base/macros.h" |
| 8 #include "build/build_config.h" |
7 #include "chrome/browser/download/download_danger_prompt.h" | 9 #include "chrome/browser/download/download_danger_prompt.h" |
8 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
9 #include "chrome/browser/safe_browsing/database_manager.h" | 11 #include "chrome/browser/safe_browsing/database_manager.h" |
10 #include "chrome/browser/safe_browsing/safe_browsing_service.h" | 12 #include "chrome/browser/safe_browsing/safe_browsing_service.h" |
11 #include "chrome/browser/ui/browser.h" | 13 #include "chrome/browser/ui/browser.h" |
12 #include "chrome/browser/ui/browser_commands.h" | 14 #include "chrome/browser/ui/browser_commands.h" |
13 #include "chrome/browser/ui/browser_tabstrip.h" | 15 #include "chrome/browser/ui/browser_tabstrip.h" |
14 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 16 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
15 #include "chrome/common/safe_browsing/csd.pb.h" | 17 #include "chrome/common/safe_browsing/csd.pb.h" |
16 #include "chrome/test/base/in_process_browser_test.h" | 18 #include "chrome/test/base/in_process_browser_test.h" |
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 download().NotifyObserversDownloadUpdated(); | 231 download().NotifyObserversDownloadUpdated(); |
230 SimulatePromptAction(DownloadDangerPrompt::ACCEPT); | 232 SimulatePromptAction(DownloadDangerPrompt::ACCEPT); |
231 VerifyExpectations(); | 233 VerifyExpectations(); |
232 | 234 |
233 // If the containing tab is closed, the dialog should DISMISS itself. | 235 // If the containing tab is closed, the dialog should DISMISS itself. |
234 OpenNewTab(); | 236 OpenNewTab(); |
235 SetUpExpectations(DownloadDangerPrompt::DISMISS); | 237 SetUpExpectations(DownloadDangerPrompt::DISMISS); |
236 chrome::CloseTab(browser()); | 238 chrome::CloseTab(browser()); |
237 VerifyExpectations(); | 239 VerifyExpectations(); |
238 } | 240 } |
OLD | NEW |