| 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 "content/renderer/browser_plugin/browser_plugin_browsertest.h" | 5 #include "content/renderer/browser_plugin/browser_plugin_browsertest.h" |
| 6 | 6 |
| 7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/memory/singleton.h" | 9 #include "base/memory/singleton.h" |
| 10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 | 91 |
| 92 DISALLOW_COPY_AND_ASSIGN(TestBrowserPluginManagerFactory); | 92 DISALLOW_COPY_AND_ASSIGN(TestBrowserPluginManagerFactory); |
| 93 }; | 93 }; |
| 94 | 94 |
| 95 BrowserPluginTest::BrowserPluginTest() {} | 95 BrowserPluginTest::BrowserPluginTest() {} |
| 96 | 96 |
| 97 BrowserPluginTest::~BrowserPluginTest() {} | 97 BrowserPluginTest::~BrowserPluginTest() {} |
| 98 | 98 |
| 99 void BrowserPluginTest::SetUp() { | 99 void BrowserPluginTest::SetUp() { |
| 100 test_content_renderer_client_.reset(new TestContentRendererClient); | 100 test_content_renderer_client_.reset(new TestContentRendererClient); |
| 101 GetContentClient()->set_renderer_for_testing( | 101 SetRendererClientForTesting(test_content_renderer_client_.get()); |
| 102 test_content_renderer_client_.get()); | |
| 103 BrowserPluginManager::set_factory_for_testing( | 102 BrowserPluginManager::set_factory_for_testing( |
| 104 TestBrowserPluginManagerFactory::GetInstance()); | 103 TestBrowserPluginManagerFactory::GetInstance()); |
| 105 content::RenderViewTest::SetUp(); | 104 content::RenderViewTest::SetUp(); |
| 106 } | 105 } |
| 107 | 106 |
| 108 void BrowserPluginTest::TearDown() { | 107 void BrowserPluginTest::TearDown() { |
| 109 BrowserPluginManager::set_factory_for_testing( | 108 BrowserPluginManager::set_factory_for_testing( |
| 110 TestBrowserPluginManagerFactory::GetInstance()); | 109 TestBrowserPluginManagerFactory::GetInstance()); |
| 111 content::RenderViewTest::TearDown(); | 110 content::RenderViewTest::TearDown(); |
| 112 test_content_renderer_client_.reset(); | 111 test_content_renderer_client_.reset(); |
| (...skipping 798 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 911 // These value are not populated (as an optimization) if autosize is | 910 // These value are not populated (as an optimization) if autosize is |
| 912 // disabled. | 911 // disabled. |
| 913 EXPECT_EQ(0, auto_size_params.min_size.width()); | 912 EXPECT_EQ(0, auto_size_params.min_size.width()); |
| 914 EXPECT_EQ(0, auto_size_params.min_size.height()); | 913 EXPECT_EQ(0, auto_size_params.min_size.height()); |
| 915 EXPECT_EQ(0, auto_size_params.max_size.width()); | 914 EXPECT_EQ(0, auto_size_params.max_size.width()); |
| 916 EXPECT_EQ(0, auto_size_params.max_size.height()); | 915 EXPECT_EQ(0, auto_size_params.max_size.height()); |
| 917 } | 916 } |
| 918 } | 917 } |
| 919 | 918 |
| 920 } // namespace content | 919 } // namespace content |
| OLD | NEW |