mod common;
mod golden;

use bone_jig::RunStatus;
use common::{find_artifact, manifest_path, run_library_scenario};
use golden::check_golden;

#[test]
fn selecting_a_body_face_in_sketch_mode_highlights_its_boundary() {
    let dir = match tempfile::tempdir() {
        Ok(d) => d,
        Err(e) => panic!("tempdir: {e}"),
    };
    let result = run_library_scenario("parity_brep_highlight.ron", dir.path());
    assert_eq!(result.status, RunStatus::Passed, "result: {result:?}");
    let snapshot = find_artifact(dir.path(), "_brep-highlight.png");
    check_golden(
        "brep-highlight",
        &snapshot,
        &manifest_path("tests/goldens/brep_highlight.png"),
        "BONE_UPDATE_BREP_HIGHLIGHT",
    );
}
