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

Unified Diff: components/mus/public/cpp/surfaces/tests/surface_unittest.cc

Issue 2014233002: Implement cc::SurfaceId StructTraits (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 7 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
« no previous file with comments | « components/mus/public/cpp/surfaces/surfaces_type_converters.cc ('k') | components/mus/public/cpp/window.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/public/cpp/surfaces/tests/surface_unittest.cc
diff --git a/components/mus/public/cpp/surfaces/tests/surface_unittest.cc b/components/mus/public/cpp/surfaces/tests/surface_unittest.cc
index eb0ed73a0616a3dba714db2ff97b2c662d78874c..b880b029393d36d4aafc4b34d7f62089a841b663 100644
--- a/components/mus/public/cpp/surfaces/tests/surface_unittest.cc
+++ b/components/mus/public/cpp/surfaces/tests/surface_unittest.cc
@@ -46,8 +46,6 @@ using mus::mojom::SharedQuadState;
using mus::mojom::SharedQuadStatePtr;
using mus::mojom::SolidColorQuadState;
using mus::mojom::SolidColorQuadStatePtr;
-using mus::mojom::SurfaceId;
-using mus::mojom::SurfaceIdPtr;
using mus::mojom::SurfaceQuadState;
using mus::mojom::SurfaceQuadStatePtr;
using mus::mojom::TextureQuadState;
@@ -63,18 +61,6 @@ using mus::mojom::YUVVideoQuadStatePtr;
namespace mojo {
namespace {
-TEST(SurfaceLibTest, SurfaceIdConverterNullId) {
- cc::SurfaceId null_id;
- cc::SurfaceId round_trip = SurfaceId::From(null_id).To<cc::SurfaceId>();
- EXPECT_TRUE(round_trip.is_null());
-}
-
-TEST(SurfaceLibTest, SurfaceIdConverterValidId) {
- cc::SurfaceId valid_id(0, 7, 0);
- cc::SurfaceId round_trip = SurfaceId::From(valid_id).To<cc::SurfaceId>();
- EXPECT_FALSE(round_trip.is_null());
- EXPECT_EQ(valid_id, round_trip);
-}
TEST(SurfaceLibTest, Color) {
SkColor arbitrary_color = SK_ColorMAGENTA;
@@ -140,7 +126,7 @@ TEST_F(SurfaceLibQuadTest, SurfaceQuad) {
EXPECT_EQ(mus::mojom::Material::SURFACE_CONTENT, mus_quad->material);
ASSERT_TRUE(mus_quad->surface_quad_state);
SurfaceQuadStatePtr& mus_surface_state = mus_quad->surface_quad_state;
- EXPECT_TRUE(SurfaceId::From(arbitrary_id).Equals(mus_surface_state->surface));
+ EXPECT_EQ(arbitrary_id, mus_surface_state->surface);
}
TEST_F(SurfaceLibQuadTest, TextureQuad) {
« no previous file with comments | « components/mus/public/cpp/surfaces/surfaces_type_converters.cc ('k') | components/mus/public/cpp/window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698