MCPcopy Index your code
hub / github.com/endbasic/endbasic / test_draw_rect_limits

Function test_draw_rect_limits

std/src/gfx/lcd/buffered/tests.rs:901–919  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

899
900#[test]
901fn test_draw_rect_limits() {
902 Tester::new(size(2, 3))
903 .op(|l| {
904 l.set_draw_color((50, 51, 52));
905 l.draw_rect(
906 PixelsXY::new(0, 0),
907 SizeInPixels::new(2, 3),
908 )
909 .unwrap()
910 })
911 .expect_pixel(xy(0, 0), (50, 51, 52))
912 .expect_pixel(xy(0, 1), (50, 51, 52))
913 .expect_pixel(xy(0, 2), (50, 51, 52))
914 .expect_pixel(xy(1, 0), (50, 51, 52))
915 .expect_pixel(xy(1, 1), (50, 51, 52))
916 .expect_pixel(xy(1, 2), (50, 51, 52))
917 .expect_op("set_data: from=(0, 0), to=(1, 2), data=[50, 51, 52, 50, 51, 52, 50, 51, 52, 50, 51, 52, 50, 51, 52, 50, 51, 52]")
918 .check();
919}
920
921#[test]
922fn test_draw_rect_clip() {

Callers

nothing calls this directly

Calls 8

expect_opMethod · 0.80
expect_pixelMethod · 0.80
opMethod · 0.80
sizeFunction · 0.70
xyFunction · 0.70
checkMethod · 0.45
set_draw_colorMethod · 0.45
draw_rectMethod · 0.45

Tested by

no test coverage detected