| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/threading/thread_task_runner_handle.h" | 6 #include "base/threading/thread_task_runner_handle.h" |
| 7 #include "chrome/app/chrome_command_ids.h" | 7 #include "chrome/app/chrome_command_ids.h" |
| 8 #include "chrome/browser/extensions/browser_action_test_util.h" | 8 #include "chrome/browser/extensions/browser_action_test_util.h" |
| 9 #include "chrome/browser/media/router/media_router_ui_service.h" | 9 #include "chrome/browser/media/router/media_router_ui_service.h" |
| 10 #include "chrome/browser/prefs/browser_prefs.h" | 10 #include "chrome/browser/prefs/browser_prefs.h" |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 | 42 |
| 43 class MediaRouterUIBrowserTest : public InProcessBrowserTest { | 43 class MediaRouterUIBrowserTest : public InProcessBrowserTest { |
| 44 public: | 44 public: |
| 45 MediaRouterUIBrowserTest() | 45 MediaRouterUIBrowserTest() |
| 46 : issue_(IssueInfo("title notification", | 46 : issue_(IssueInfo("title notification", |
| 47 IssueInfo::Action::DISMISS, | 47 IssueInfo::Action::DISMISS, |
| 48 IssueInfo::Severity::NOTIFICATION)) {} | 48 IssueInfo::Severity::NOTIFICATION)) {} |
| 49 ~MediaRouterUIBrowserTest() override {} | 49 ~MediaRouterUIBrowserTest() override {} |
| 50 | 50 |
| 51 void SetUpOnMainThread() override { | 51 void SetUpOnMainThread() override { |
| 52 InProcessBrowserTest::SetUpOnMainThread(); | |
| 53 | |
| 54 BrowserActionsContainer* browser_actions_container = | 52 BrowserActionsContainer* browser_actions_container = |
| 55 BrowserView::GetBrowserViewForBrowser(browser()) | 53 BrowserView::GetBrowserViewForBrowser(browser()) |
| 56 ->toolbar() | 54 ->toolbar() |
| 57 ->browser_actions(); | 55 ->browser_actions(); |
| 58 ASSERT_TRUE(browser_actions_container); | 56 ASSERT_TRUE(browser_actions_container); |
| 59 toolbar_actions_bar_ = browser_actions_container->toolbar_actions_bar(); | 57 toolbar_actions_bar_ = browser_actions_container->toolbar_actions_bar(); |
| 60 | 58 |
| 61 action_controller_ = | 59 action_controller_ = |
| 62 MediaRouterUIService::Get(browser()->profile())->action_controller(); | 60 MediaRouterUIService::Get(browser()->profile())->action_controller(); |
| 63 | 61 |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 376 } | 374 } |
| 377 | 375 |
| 378 IN_PROC_BROWSER_TEST_F(MediaRouterUIBrowserTest, | 376 IN_PROC_BROWSER_TEST_F(MediaRouterUIBrowserTest, |
| 379 MigrateToolbarIconUnshownPref) { | 377 MigrateToolbarIconUnshownPref) { |
| 380 MigrateToolbarIconPref(false); | 378 MigrateToolbarIconPref(false); |
| 381 EXPECT_FALSE(MediaRouterActionController::GetAlwaysShowActionPref( | 379 EXPECT_FALSE(MediaRouterActionController::GetAlwaysShowActionPref( |
| 382 browser()->profile())); | 380 browser()->profile())); |
| 383 } | 381 } |
| 384 | 382 |
| 385 } // namespace media_router | 383 } // namespace media_router |
| OLD | NEW |