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 "ash/shell.h" | 5 #include "ash/shell.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/ash_switches.h" | 10 #include "ash/ash_switches.h" |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
260 | 260 |
261 TEST_F(ShellTest, IsScreenLocked) { | 261 TEST_F(ShellTest, IsScreenLocked) { |
262 ash::Shell::GetInstance()->delegate()->LockScreen(); | 262 ash::Shell::GetInstance()->delegate()->LockScreen(); |
263 EXPECT_TRUE(Shell::GetInstance()->IsScreenLocked()); | 263 EXPECT_TRUE(Shell::GetInstance()->IsScreenLocked()); |
264 ash::Shell::GetInstance()->delegate()->UnlockScreen(); | 264 ash::Shell::GetInstance()->delegate()->UnlockScreen(); |
265 EXPECT_FALSE(Shell::GetInstance()->IsScreenLocked()); | 265 EXPECT_FALSE(Shell::GetInstance()->IsScreenLocked()); |
266 } | 266 } |
267 | 267 |
268 // Fails on Mac, see http://crbug.com/115662 | 268 // Fails on Mac, see http://crbug.com/115662 |
269 #if defined(OS_MACOSX) | 269 #if defined(OS_MACOSX) |
270 #define MAYBE_ManagedWindowModeBasics FAILS_ManagedWindowModeBasics | 270 #define MAYBE_ManagedWindowModeBasics DISABLED_ManagedWindowModeBasics |
271 #else | 271 #else |
272 #define MAYBE_ManagedWindowModeBasics ManagedWindowModeBasics | 272 #define MAYBE_ManagedWindowModeBasics ManagedWindowModeBasics |
273 #endif | 273 #endif |
274 TEST_F(ShellTest, MAYBE_ManagedWindowModeBasics) { | 274 TEST_F(ShellTest, MAYBE_ManagedWindowModeBasics) { |
275 Shell* shell = Shell::GetInstance(); | 275 Shell* shell = Shell::GetInstance(); |
276 Shell::TestApi test_api(shell); | 276 Shell::TestApi test_api(shell); |
277 | 277 |
278 // We start with the usual window containers. | 278 // We start with the usual window containers. |
279 ExpectAllContainers(); | 279 ExpectAllContainers(); |
280 // Launcher is visible. | 280 // Launcher is visible. |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
405 private: | 405 private: |
406 DISALLOW_COPY_AND_ASSIGN(ShellTest2); | 406 DISALLOW_COPY_AND_ASSIGN(ShellTest2); |
407 }; | 407 }; |
408 | 408 |
409 TEST_F(ShellTest2, DontCrashWhenWindowDeleted) { | 409 TEST_F(ShellTest2, DontCrashWhenWindowDeleted) { |
410 window_.reset(new aura::Window(NULL)); | 410 window_.reset(new aura::Window(NULL)); |
411 window_->Init(ui::LAYER_NOT_DRAWN); | 411 window_->Init(ui::LAYER_NOT_DRAWN); |
412 } | 412 } |
413 | 413 |
414 } // namespace ash | 414 } // namespace ash |
OLD | NEW |