Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 6603682

Browse files
author
jonahwilliams
committed
add test.
1 parent bd1cedb commit 6603682

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

impeller/entity/entity_unittests.cc

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1605,6 +1605,20 @@ TEST_P(EntityTest, SolidFillShouldRenderIsCorrect) {
16051605
}
16061606
}
16071607

1608+
TEST_P(EntityTest, DoesNotCullEntitiesByDefault) {
1609+
auto fill = std::make_shared<SolidColorContents>();
1610+
fill->SetColor(Color::CornflowerBlue());
1611+
fill->SetGeometry(
1612+
Geometry::MakeRect(Rect::MakeLTRB(-1000, -1000, -900, -900)));
1613+
1614+
Entity entity;
1615+
entity.SetContents(fill);
1616+
1617+
// Even though the entity is offscreen, this should still render because we do
1618+
// not compute the coverage intersection by default.
1619+
EXPECT_TRUE(entity.ShouldRender(Rect::MakeLTRB(0, 0, 100, 100)));
1620+
}
1621+
16081622
TEST_P(EntityTest, ClipContentsShouldRenderIsCorrect) {
16091623
// For clip ops, `ShouldRender` should always return true.
16101624

0 commit comments

Comments
 (0)