Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "chromecast/graphics/cast_window_manager.h" | |
| 6 | |
| 7 #include <memory> | |
| 8 | |
| 9 #include "ui/aura/test/aura_test_base.h" | |
| 10 #include "ui/aura/window.h" | |
| 11 #include "ui/aura_extra/image_window_delegate.h" | |
| 12 | |
| 13 namespace chromecast { | |
| 14 namespace test { | |
| 15 | |
| 16 using CastWindowManagerAuraTest = aura::test::AuraTestBase; | |
| 17 | |
| 18 TEST_F(CastWindowManagerAuraTest, SolidWindow) { | |
| 19 std::unique_ptr<CastWindowManager> window_manager( | |
| 20 CastWindowManager::Create(true /* enable input */)); | |
| 21 | |
| 22 aura_extra::ImageWindowDelegate* window_delegate( | |
| 23 new aura_extra::ImageWindowDelegate); | |
| 24 window_delegate->set_background_color(SK_ColorBLACK); | |
| 25 std::unique_ptr<aura::Window> window(new aura::Window(window_delegate)); | |
| 26 window->Init(ui::LAYER_TEXTURED); | |
| 27 window_manager->AddWindow(window.get()); | |
| 28 window->SetBounds(gfx::Rect(0, 0, 1280, 720)); | |
| 29 window->Show(); | |
|
halliwell
2017/01/24 00:54:46
What's this test checking? :)
Joshua LeVasseur
2017/01/24 03:39:50
I'd like to check that it displays the window, but
halliwell
2017/01/24 04:10:12
Fair enough. Maybe can find some useful assertion
| |
| 30 } | |
| 31 | |
| 32 } // namespace test | |
| 33 } // namespace chromecast | |
| OLD | NEW |