OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/string_number_conversions.h" | 6 #include "base/string_number_conversions.h" |
7 #include "chrome/browser/download/download_service.h" | 7 #include "chrome/browser/download/download_service.h" |
8 #include "chrome/browser/download/download_service_factory.h" | 8 #include "chrome/browser/download/download_service_factory.h" |
9 #include "chrome/browser/net/url_request_mock_util.h" | 9 #include "chrome/browser/net/url_request_mock_util.h" |
10 #include "chrome/browser/prefs/pref_service.h" | 10 #include "chrome/browser/prefs/pref_service.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "chrome/common/pref_names.h" | 23 #include "chrome/common/pref_names.h" |
24 #include "chrome/common/url_constants.h" | 24 #include "chrome/common/url_constants.h" |
25 #include "chrome/test/base/ui_test_utils.h" | 25 #include "chrome/test/base/ui_test_utils.h" |
26 #include "content/browser/download/download_manager.h" | 26 #include "content/browser/download/download_manager.h" |
27 #include "content/browser/net/url_request_mock_http_job.h" | 27 #include "content/browser/net/url_request_mock_http_job.h" |
28 #include "content/browser/tab_contents/tab_contents.h" | 28 #include "content/browser/tab_contents/tab_contents.h" |
29 #include "content/public/browser/notification_service.h" | 29 #include "content/public/browser/notification_service.h" |
30 #include "content/public/common/url_constants.h" | 30 #include "content/public/common/url_constants.h" |
31 #include "testing/gtest/include/gtest/gtest.h" | 31 #include "testing/gtest/include/gtest/gtest.h" |
32 | 32 |
| 33 using content::BrowserThread; |
| 34 |
33 class PanelBrowserTest : public BasePanelBrowserTest { | 35 class PanelBrowserTest : public BasePanelBrowserTest { |
34 public: | 36 public: |
35 PanelBrowserTest() : BasePanelBrowserTest() { | 37 PanelBrowserTest() : BasePanelBrowserTest() { |
36 } | 38 } |
37 | 39 |
38 protected: | 40 protected: |
39 void CloseWindowAndWait(Browser* browser) { | 41 void CloseWindowAndWait(Browser* browser) { |
40 // Closing a browser window may involve several async tasks. Need to use | 42 // Closing a browser window may involve several async tasks. Need to use |
41 // message pump and wait for the notification. | 43 // message pump and wait for the notification. |
42 size_t browser_count = BrowserList::size(); | 44 size_t browser_count = BrowserList::size(); |
(...skipping 1509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1552 EXPECT_EQ(1, tabbed_browser->tab_count()); | 1554 EXPECT_EQ(1, tabbed_browser->tab_count()); |
1553 ASSERT_TRUE(tabbed_browser->window()->IsDownloadShelfVisible()); | 1555 ASSERT_TRUE(tabbed_browser->window()->IsDownloadShelfVisible()); |
1554 tabbed_browser->CloseWindow(); | 1556 tabbed_browser->CloseWindow(); |
1555 #endif | 1557 #endif |
1556 | 1558 |
1557 EXPECT_EQ(1, panel_browser->tab_count()); | 1559 EXPECT_EQ(1, panel_browser->tab_count()); |
1558 ASSERT_FALSE(panel_browser->window()->IsDownloadShelfVisible()); | 1560 ASSERT_FALSE(panel_browser->window()->IsDownloadShelfVisible()); |
1559 | 1561 |
1560 panel_browser->CloseWindow(); | 1562 panel_browser->CloseWindow(); |
1561 } | 1563 } |
OLD | NEW |