MCPcopy Create free account
hub / github.com/dejwk/roo_display / TEST

Function TEST

test/basic_shapes_test.cpp:10–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8namespace roo_display {
9
10TEST(BasicShapes, FillRectOutOfBounds) {
11 FakeOffscreen<Rgb565> test_screen(2, 3);
12 Display display(test_screen);
13 {
14 DrawingContext dc(display);
15 // Intentionally write out-of-bounds to test that it is caught by
16 // the shape.
17 dc.draw(FilledRect(-5, -2, 8, 7, color::Black));
18 }
19 EXPECT_THAT(test_screen, MatchesContent(WhiteOnBlack(), 2, 3,
20 " "
21 " "
22 " "));
23}
24
25TEST(BasicShapes, FillRectOpaque) {
26 FakeOffscreen<Rgb565> test_screen(5, 6, color::Black);

Callers

nothing calls this directly

Calls 15

FilledRectClass · 0.85
MatchesContentFunction · 0.85
WhiteOnBlackFunction · 0.85
ForcedStreamableClass · 0.85
ForcedRasterizableClass · 0.85
Rgb565Class · 0.85
BoxClass · 0.85
ColorClass · 0.85
ForceFillRectFunction · 0.85
Grayscale4Class · 0.85
FilledRoundRectClass · 0.85
LineClass · 0.85

Tested by

no test coverage detected