#include "ui/compositor/canvas_painter.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/compositor/paint_recorder.h"
#include "ui/gfx/canvas.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/geometry/size.h"
namespace ui {
namespace {
void CheckPaintedShape(const SkBitmap& bitmap,
const gfx::Rect& shape_bounds,
const SkColor shape_color,
float device_scale_factor) { … }
}
class CanvasPainterTest : public ::testing::TestWithParam<float> { … };
TEST_P(CanvasPainterTest, Initialization) { … }
TEST_P(CanvasPainterTest, InitializationPixelCanvasEnabled) { … }
TEST_P(CanvasPainterTest, Paint) { … }
TEST_P(CanvasPainterTest, PaintPixelCanvasEnabled) { … }
INSTANTIATE_TEST_SUITE_P(…);
}