Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(52)

Side by Side Diff: ash/common/devtools/ash_devtools_unittest.cc

Issue 2738133003: Promotes a handful of members from WmShell to Shell (Closed)
Patch Set: merge Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ash/common/devtools/ash_devtools_dom_agent.cc ('k') | ash/common/keyboard/keyboard_ui.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/common/devtools/ash_devtools_css_agent.h" 5 #include "ash/common/devtools/ash_devtools_css_agent.h"
6 #include "ash/common/devtools/ash_devtools_dom_agent.h" 6 #include "ash/common/devtools/ash_devtools_dom_agent.h"
7 #include "ash/common/test/ash_test.h" 7 #include "ash/common/test/ash_test.h"
8 #include "ash/common/wm_shell.h" 8 #include "ash/common/wm_shell.h"
9 #include "ash/common/wm_window.h" 9 #include "ash/common/wm_window.h"
10 #include "ash/root_window_controller.h" 10 #include "ash/root_window_controller.h"
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 widget, kShellWindowId_DefaultContainer, &params); 192 widget, kShellWindowId_DefaultContainer, &params);
193 widget->Init(params); 193 widget->Init(params);
194 return widget->native_widget_private(); 194 return widget->native_widget_private();
195 } 195 }
196 196
197 void SetUp() override { 197 void SetUp() override {
198 AshTest::SetUp(); 198 AshTest::SetUp();
199 fake_frontend_channel_ = base::MakeUnique<FakeFrontendChannel>(); 199 fake_frontend_channel_ = base::MakeUnique<FakeFrontendChannel>();
200 uber_dispatcher_ = 200 uber_dispatcher_ =
201 base::MakeUnique<UberDispatcher>(fake_frontend_channel_.get()); 201 base::MakeUnique<UberDispatcher>(fake_frontend_channel_.get());
202 dom_agent_ = 202 dom_agent_ = base::MakeUnique<devtools::AshDevToolsDOMAgent>();
203 base::MakeUnique<devtools::AshDevToolsDOMAgent>(WmShell::Get());
204 dom_agent_->Init(uber_dispatcher_.get()); 203 dom_agent_->Init(uber_dispatcher_.get());
205 css_agent_ = 204 css_agent_ =
206 base::MakeUnique<devtools::AshDevToolsCSSAgent>(dom_agent_.get()); 205 base::MakeUnique<devtools::AshDevToolsCSSAgent>(dom_agent_.get());
207 css_agent_->Init(uber_dispatcher_.get()); 206 css_agent_->Init(uber_dispatcher_.get());
208 css_agent_->enable(); 207 css_agent_->enable();
209 } 208 }
210 209
211 void TearDown() override { 210 void TearDown() override {
212 css_agent_.reset(); 211 css_agent_.reset();
213 dom_agent_.reset(); 212 dom_agent_.reset();
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
756 EXPECT_EQ(gfx::Rect(25, 35, 45, 20), root_view->bounds()); // Not changed 755 EXPECT_EQ(gfx::Rect(25, 35, 45, 20), root_view->bounds()); // Not changed
757 756
758 SetStyleTexts(root_view_node, "\nheight: 73;\n ", true); 757 SetStyleTexts(root_view_node, "\nheight: 73;\n ", true);
759 EXPECT_EQ(gfx::Rect(25, 35, 45, 73), root_view->bounds()); 758 EXPECT_EQ(gfx::Rect(25, 35, 45, 73), root_view->bounds());
760 759
761 SetStyleTexts(root_view_node, "\nx: 10; y: 23; width: 52;\n ", true); 760 SetStyleTexts(root_view_node, "\nx: 10; y: 23; width: 52;\n ", true);
762 EXPECT_EQ(gfx::Rect(10, 23, 52, 73), root_view->bounds()); 761 EXPECT_EQ(gfx::Rect(10, 23, 52, 73), root_view->bounds());
763 } 762 }
764 763
765 } // namespace ash 764 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/devtools/ash_devtools_dom_agent.cc ('k') | ash/common/keyboard/keyboard_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698