| Index: ash/app_list/app_list_presenter_delegate_unittest.cc
|
| diff --git a/ash/app_list/app_list_presenter_delegate_unittest.cc b/ash/app_list/app_list_presenter_delegate_unittest.cc
|
| index 00525dcaed7b49ef7da84c268332dc6c93942fa9..d554816c4b30abc599c2ef45436ad97f7e2baf9f 100644
|
| --- a/ash/app_list/app_list_presenter_delegate_unittest.cc
|
| +++ b/ash/app_list/app_list_presenter_delegate_unittest.cc
|
| @@ -4,7 +4,6 @@
|
|
|
| #include <memory>
|
|
|
| -#include "ash/ash_switches.h"
|
| #include "ash/public/cpp/shell_window_ids.h"
|
| #include "ash/shell.h"
|
| #include "ash/shell_port.h"
|
| @@ -12,9 +11,7 @@
|
| #include "ash/test/test_app_list_view_presenter_impl.h"
|
| #include "ash/wm/window_util.h"
|
| #include "ash/wm_window.h"
|
| -#include "base/command_line.h"
|
| #include "base/macros.h"
|
| -#include "ui/app_list/app_list_switches.h"
|
| #include "ui/app_list/views/app_list_view.h"
|
| #include "ui/aura/test/test_windows.h"
|
| #include "ui/aura/window.h"
|
| @@ -29,15 +26,9 @@
|
| return display::Screen::GetScreen()->GetPrimaryDisplay().id();
|
| }
|
|
|
| -void SetFullscreenAppListSwitch() {
|
| - base::CommandLine::ForCurrentProcess()->AppendSwitch(
|
| - app_list::switches::kEnableFullscreenAppList);
|
| -}
|
| -
|
| } // namespace
|
|
|
| -class AppListPresenterDelegateTest : public test::AshTestBase,
|
| - public testing::WithParamInterface<bool> {
|
| +class AppListPresenterDelegateTest : public test::AshTestBase {
|
| public:
|
| AppListPresenterDelegateTest() {}
|
| ~AppListPresenterDelegateTest() override {}
|
| @@ -50,29 +41,18 @@
|
| void SetUp() override {
|
| AshTestBase::SetUp();
|
|
|
| - // If the current test is parameterized.
|
| - if (testing::UnitTest::GetInstance()->current_test_info()->value_param()) {
|
| - test_with_fullscreen_ = GetParam();
|
| - if (test_with_fullscreen_)
|
| - SetFullscreenAppListSwitch();
|
| - }
|
| // Make the display big enough to hold the app list.
|
| UpdateDisplay("1024x768");
|
| }
|
|
|
| private:
|
| test::TestAppListViewPresenterImpl app_list_presenter_impl_;
|
| - bool test_with_fullscreen_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(AppListPresenterDelegateTest);
|
| };
|
|
|
| -// Instantiate the Boolean which is used to toggle the Fullscreen app list in
|
| -// the parameterized tests.
|
| -INSTANTIATE_TEST_CASE_P(, AppListPresenterDelegateTest, testing::Bool());
|
| -
|
| // Tests that app launcher hides when focus moves to a normal window.
|
| -TEST_P(AppListPresenterDelegateTest, HideOnFocusOut) {
|
| +TEST_F(AppListPresenterDelegateTest, HideOnFocusOut) {
|
| app_list_presenter_impl()->Show(GetPrimaryDisplayId());
|
| EXPECT_TRUE(app_list_presenter_impl()->GetTargetVisibility());
|
|
|
| @@ -84,7 +64,7 @@
|
|
|
| // Tests that app launcher remains visible when focus is moved to a different
|
| // window in kShellWindowId_AppListContainer.
|
| -TEST_P(AppListPresenterDelegateTest,
|
| +TEST_F(AppListPresenterDelegateTest,
|
| RemainVisibleWhenFocusingToApplistContainer) {
|
| app_list_presenter_impl()->Show(GetPrimaryDisplayId());
|
| EXPECT_TRUE(app_list_presenter_impl()->GetTargetVisibility());
|
| @@ -142,7 +122,7 @@
|
|
|
| // Tests opening the app launcher on a non-primary display, then deleting the
|
| // display.
|
| -TEST_P(AppListPresenterDelegateTest, NonPrimaryDisplay) {
|
| +TEST_F(AppListPresenterDelegateTest, NonPrimaryDisplay) {
|
| // Set up a screen with two displays (horizontally adjacent).
|
| UpdateDisplay("1024x768,1024x768");
|
|
|
| @@ -176,12 +156,10 @@
|
| // from the anchor (center) and height. There isn't a bounds rect that gives
|
| // the actual app list position (the widget bounds include the bubble border
|
| // which is much bigger than the actual app list size).
|
| -
|
| app_list::AppListView* app_list = app_list_presenter_impl()->GetView();
|
| int app_list_view_top =
|
| app_list->anchor_rect().y() - app_list->bounds().height() / 2;
|
| const int kMinimalAppListMargin = 10;
|
| -
|
| EXPECT_GE(app_list_view_top, kMinimalAppListMargin);
|
| }
|
|
|
|
|