| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/files/file_path.h" | 6 #include "base/files/file_path.h" |
| 7 #include "base/message_loop/message_loop.h" | 7 #include "base/message_loop/message_loop.h" |
| 8 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
| 9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
| 10 #include "chrome/browser/chrome_notification_types.h" | 10 #include "chrome/browser/chrome_notification_types.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 #include "content/public/browser/render_frame_host.h" | 38 #include "content/public/browser/render_frame_host.h" |
| 39 #include "content/public/browser/render_view_host.h" | 39 #include "content/public/browser/render_view_host.h" |
| 40 #include "content/public/browser/web_contents.h" | 40 #include "content/public/browser/web_contents.h" |
| 41 #include "content/public/browser/web_contents_observer.h" | 41 #include "content/public/browser/web_contents_observer.h" |
| 42 #include "content/public/common/url_constants.h" | 42 #include "content/public/common/url_constants.h" |
| 43 #include "content/public/test/browser_test_utils.h" | 43 #include "content/public/test/browser_test_utils.h" |
| 44 #include "content/public/test/test_navigation_observer.h" | 44 #include "content/public/test/test_navigation_observer.h" |
| 45 #include "net/dns/mock_host_resolver.h" | 45 #include "net/dns/mock_host_resolver.h" |
| 46 #include "net/test/embedded_test_server/embedded_test_server.h" | 46 #include "net/test/embedded_test_server/embedded_test_server.h" |
| 47 #include "testing/gtest/include/gtest/gtest.h" | 47 #include "testing/gtest/include/gtest/gtest.h" |
| 48 #include "ui/events/keycodes/dom4/keycode_converter.h" | 48 #include "ui/events/keycodes/dom/keycode_converter.h" |
| 49 | 49 |
| 50 using content::WebContents; | 50 using content::WebContents; |
| 51 using content::NativeWebKeyboardEvent; | 51 using content::NativeWebKeyboardEvent; |
| 52 | 52 |
| 53 namespace { | 53 namespace { |
| 54 | 54 |
| 55 // Counts the number of RenderViewHosts created. | 55 // Counts the number of RenderViewHosts created. |
| 56 class CountRenderViewHosts : public content::NotificationObserver { | 56 class CountRenderViewHosts : public content::NotificationObserver { |
| 57 public: | 57 public: |
| 58 CountRenderViewHosts() | 58 CountRenderViewHosts() |
| (...skipping 639 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 698 wait_for_new_tab.Wait(); | 698 wait_for_new_tab.Wait(); |
| 699 | 699 |
| 700 ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile(), | 700 ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile(), |
| 701 browser()->host_desktop_type())); | 701 browser()->host_desktop_type())); |
| 702 ASSERT_EQ(2, browser()->tab_strip_model()->count()); | 702 ASSERT_EQ(2, browser()->tab_strip_model()->count()); |
| 703 // Check that we create the background tab. | 703 // Check that we create the background tab. |
| 704 ASSERT_EQ(0, browser()->tab_strip_model()->active_index()); | 704 ASSERT_EQ(0, browser()->tab_strip_model()->active_index()); |
| 705 } | 705 } |
| 706 | 706 |
| 707 } // namespace | 707 } // namespace |
| OLD | NEW |