#![cfg(feature = "software_renderer")]
use raylib::prelude::*;
use raylib::test_harness::{assert_pixel, render_frame, with_headless};
#[test]
fn shapes_render_expected_pixels() {
with_headless(64, 64, |rl, thread| {
let img = render_frame(rl, thread, |d| {
d.clear_background(Color::BLACK);
d.draw_rectangle(8, 8, 16, 16, Color::RED); d.draw_circle(48, 48, 8.0, Color::GREEN); d.draw_line(0, 0, 63, 0, Color::BLUE); });
assert_pixel(&img, 40, 20, Color::BLACK, 8);
assert_pixel(&img, 16, 16, Color::RED, 16);
assert_pixel(&img, 48, 48, Color::GREEN, 16);
assert_pixel(&img, 32, 1, Color::BLUE, 16);
});
}