Index: sky/compositor/display_delegate_bitmap.cc |
diff --git a/sky/compositor/display_delegate_bitmap.cc b/sky/compositor/display_delegate_bitmap.cc |
index 571eda1f5360f3e754a64fbabf1dafe51dbce0e3..4a8a149d47ca1eb7ccad1e07ba22ee4343cc3e12 100644 |
--- a/sky/compositor/display_delegate_bitmap.cc |
+++ b/sky/compositor/display_delegate_bitmap.cc |
@@ -22,7 +22,8 @@ DisplayDelegate* DisplayDelegateBitmap::create(LayerClient* client) { |
} |
void DisplayDelegateBitmap::GetPixelsForTesting(std::vector<unsigned char>* pixels) { |
- gfx::PNGCodec::EncodeBGRASkBitmap(bitmap_, false, pixels); |
+ bool success = gfx::PNGCodec::EncodeBGRASkBitmap(bitmap_, false, pixels); |
+ CHECK(success) << "Could not dump pixels. Did you call notifyTestComplete before the first paint?"; |
} |
void DisplayDelegateBitmap::Paint(mojo::GaneshSurface& surface, const gfx::Rect& size) { |