diff --git a/impeller/entity/entity_unittests.cc b/impeller/entity/entity_unittests.cc index 1592bcb1198f1..7dcebc01f8117 100644 --- a/impeller/entity/entity_unittests.cc +++ b/impeller/entity/entity_unittests.cc @@ -2798,6 +2798,20 @@ TEST_P(EntityTest, FillPathGeometryGetPositionBufferReturnsExpectedMode) { } } +TEST_P(EntityTest, FailOnValidationError) { + if (GetParam() != PlaygroundBackend::kVulkan) { + GTEST_SKIP() << "Validation is only fatal on Vulkan backend."; + } + EXPECT_DEATH( + // The easiest way to trigger a validation error is to try to compile + // a shader with an unsupported pixel format. + GetContentContext()->GetBlendColorBurnPipeline({ + .color_attachment_pixel_format = PixelFormat::kUnknown, + .has_depth_stencil_attachments = false, + }), + ""); +} + } // namespace testing } // namespace impeller