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

Unified Diff: extensions/shell/browser/shell_screen_unittest.cc

Issue 2361283002: Add GetDisplayWithDisplayId to display::Screen. (Closed)
Patch Set: id Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: extensions/shell/browser/shell_screen_unittest.cc
diff --git a/extensions/shell/browser/shell_screen_unittest.cc b/extensions/shell/browser/shell_screen_unittest.cc
index 75a5cd161ae334b8e3719f424e96bc5b9dd87bd9..b0f3bdf643617fa2a5aaf6214a8c0d5e57cf92b7 100644
--- a/extensions/shell/browser/shell_screen_unittest.cc
+++ b/extensions/shell/browser/shell_screen_unittest.cc
@@ -26,8 +26,12 @@ TEST_F(ShellScreenTest, ShellScreen) {
EXPECT_EQ(1, screen.GetNumDisplays());
EXPECT_EQ(1u, screen.GetAllDisplays().size());
EXPECT_EQ(0, screen.GetAllDisplays()[0].id());
+ display::Display display;
+ bool has_display = screen.GetDisplayWithDisplayId(0, &display);
+ EXPECT_TRUE(has_display);
+ EXPECT_EQ(0, display.id());
EXPECT_EQ(0, screen.GetPrimaryDisplay().id());
- EXPECT_EQ("640x480", screen.GetPrimaryDisplay().size().ToString());
+ EXPECT_EQ("640x480", display.size().ToString());
// Tests that reshaping the host window reshapes the display.
// NOTE: AuraTestBase already has its own WindowTreeHost. This is creating a

Powered by Google App Engine
This is Rietveld 408576698