| Index: chrome/browser/ui/cocoa/notifications/balloon_controller_unittest.mm
|
| diff --git a/chrome/browser/ui/cocoa/notifications/balloon_controller_unittest.mm b/chrome/browser/ui/cocoa/notifications/balloon_controller_unittest.mm
|
| index a58c9be1dcd868a42c8e89b3a2775c7c9130388a..15e1ff4bd76adf872e4991d6c1803790ca158880 100644
|
| --- a/chrome/browser/ui/cocoa/notifications/balloon_controller_unittest.mm
|
| +++ b/chrome/browser/ui/cocoa/notifications/balloon_controller_unittest.mm
|
| @@ -10,8 +10,8 @@
|
| #include "chrome/browser/ui/browser.h"
|
| #include "chrome/browser/ui/cocoa/cocoa_test_helper.h"
|
| #include "chrome/browser/ui/cocoa/notifications/balloon_controller.h"
|
| +#include "chrome/test/base/chrome_render_view_host_test_harness.h"
|
| #include "chrome/test/base/testing_profile.h"
|
| -#include "content/browser/renderer_host/test_render_view_host.h"
|
|
|
| // Subclass balloon controller and mock out the initialization of the RVH.
|
| @interface TestBalloonController : BalloonController {
|
| @@ -45,7 +45,7 @@ class MockBalloonCollection : public BalloonCollection {
|
| Balloons balloons_;
|
| };
|
|
|
| -class BalloonControllerTest : public RenderViewHostTestHarness {
|
| +class BalloonControllerTest : public ChromeRenderViewHostTestHarness {
|
| public:
|
| BalloonControllerTest() :
|
| ui_thread_(BrowserThread::UI, MessageLoop::current()),
|
| @@ -53,23 +53,21 @@ class BalloonControllerTest : public RenderViewHostTestHarness {
|
| }
|
|
|
| virtual void SetUp() {
|
| - RenderViewHostTestHarness::SetUp();
|
| + ChromeRenderViewHostTestHarness::SetUp();
|
| CocoaTest::BootstrapCocoa();
|
| - profile_.reset(new TestingProfile());
|
| - profile_->CreateRequestContext();
|
| - browser_.reset(new Browser(Browser::TYPE_TABBED, profile_.get()));
|
| + profile()->CreateRequestContext();
|
| + browser_.reset(new Browser(Browser::TYPE_TABBED, profile()));
|
| collection_.reset(new MockBalloonCollection());
|
| }
|
|
|
| virtual void TearDown() {
|
| MessageLoop::current()->RunAllPending();
|
| - RenderViewHostTestHarness::TearDown();
|
| + ChromeRenderViewHostTestHarness::TearDown();
|
| }
|
|
|
| protected:
|
| BrowserThread ui_thread_;
|
| BrowserThread io_thread_;
|
| - scoped_ptr<TestingProfile> profile_;
|
| scoped_ptr<Browser> browser_;
|
| scoped_ptr<BalloonCollection> collection_;
|
| };
|
| @@ -79,7 +77,7 @@ TEST_F(BalloonControllerTest, ShowAndCloseTest) {
|
| ASCIIToUTF16("http://www.google.com"), string16(),
|
| new NotificationObjectProxy(-1, -1, -1, false));
|
| scoped_ptr<Balloon> balloon(
|
| - new Balloon(n, profile_.get(), collection_.get()));
|
| + new Balloon(n, profile(), collection_.get()));
|
| balloon->SetPosition(gfx::Point(1, 1), false);
|
| balloon->set_content_size(gfx::Size(100, 100));
|
|
|
| @@ -95,7 +93,7 @@ TEST_F(BalloonControllerTest, SizesTest) {
|
| ASCIIToUTF16("http://www.google.com"), string16(),
|
| new NotificationObjectProxy(-1, -1, -1, false));
|
| scoped_ptr<Balloon> balloon(
|
| - new Balloon(n, profile_.get(), collection_.get()));
|
| + new Balloon(n, profile(), collection_.get()));
|
| balloon->SetPosition(gfx::Point(1, 1), false);
|
| balloon->set_content_size(gfx::Size(100, 100));
|
|
|
|
|