OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "ash/display/mirror_window_controller.h" | 5 #include "ash/display/mirror_window_controller.h" |
6 | 6 |
7 #include "ash/ash_switches.h" | 7 #include "ash/ash_switches.h" |
8 #include "ash/display/display_manager.h" | 8 #include "ash/display/display_manager.h" |
9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
10 #include "ash/test/ash_test_base.h" | 10 #include "ash/test/ash_test_base.h" |
(...skipping 15 matching lines...) Expand all Loading... |
26 DisplayInfo info(id, base::StringPrintf("x-%d", static_cast<int>(id)), false); | 26 DisplayInfo info(id, base::StringPrintf("x-%d", static_cast<int>(id)), false); |
27 info.SetBounds(bounds); | 27 info.SetBounds(bounds); |
28 return info; | 28 return info; |
29 } | 29 } |
30 | 30 |
31 class MirrorOnBootTest : public test::AshTestBase { | 31 class MirrorOnBootTest : public test::AshTestBase { |
32 public: | 32 public: |
33 MirrorOnBootTest() {} | 33 MirrorOnBootTest() {} |
34 virtual ~MirrorOnBootTest() {} | 34 virtual ~MirrorOnBootTest() {} |
35 | 35 |
36 virtual void SetUp() OVERRIDE { | 36 virtual void SetUp() override { |
37 CommandLine::ForCurrentProcess()->AppendSwitchASCII( | 37 CommandLine::ForCurrentProcess()->AppendSwitchASCII( |
38 switches::kAshHostWindowBounds, "1+1-300x300,1+301-300x300"); | 38 switches::kAshHostWindowBounds, "1+1-300x300,1+301-300x300"); |
39 CommandLine::ForCurrentProcess()->AppendSwitch( | 39 CommandLine::ForCurrentProcess()->AppendSwitch( |
40 switches::kAshEnableSoftwareMirroring); | 40 switches::kAshEnableSoftwareMirroring); |
41 test::AshTestBase::SetUp(); | 41 test::AshTestBase::SetUp(); |
42 } | 42 } |
43 virtual void TearDown() OVERRIDE { | 43 virtual void TearDown() override { |
44 test::AshTestBase::TearDown(); | 44 test::AshTestBase::TearDown(); |
45 } | 45 } |
46 | 46 |
47 private: | 47 private: |
48 DISALLOW_COPY_AND_ASSIGN(MirrorOnBootTest); | 48 DISALLOW_COPY_AND_ASSIGN(MirrorOnBootTest); |
49 }; | 49 }; |
50 | 50 |
51 } | 51 } |
52 | 52 |
53 typedef test::AshTestBase MirrorWindowControllerTest; | 53 typedef test::AshTestBase MirrorWindowControllerTest; |
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
280 | 280 |
281 TEST_F(MirrorOnBootTest, MAYBE_MirrorOnBoot) { | 281 TEST_F(MirrorOnBootTest, MAYBE_MirrorOnBoot) { |
282 DisplayManager* display_manager = Shell::GetInstance()->display_manager(); | 282 DisplayManager* display_manager = Shell::GetInstance()->display_manager(); |
283 EXPECT_TRUE(display_manager->IsMirrored()); | 283 EXPECT_TRUE(display_manager->IsMirrored()); |
284 RunAllPendingInMessageLoop(); | 284 RunAllPendingInMessageLoop(); |
285 test::MirrorWindowTestApi test_api; | 285 test::MirrorWindowTestApi test_api; |
286 EXPECT_TRUE(test_api.GetHost()); | 286 EXPECT_TRUE(test_api.GetHost()); |
287 } | 287 } |
288 | 288 |
289 } // namespace ash | 289 } // namespace ash |
OLD | NEW |