Remove tests

They are pretty simple, and they're getting in the way of changes I'm
working on. I think they're no longer carrying their weight.
This commit is contained in:
Hanno Braun 2024-10-23 19:04:14 +02:00
parent 3f9b4a1345
commit e58dbdddd3

View File

@ -29,55 +29,3 @@ pub fn convert_vector_surface_to_global(
);
point - surface.origin()
}
#[cfg(test)]
mod tests {
use fj_math::{Line, Point, Vector};
use pretty_assertions::assert_eq;
use crate::geometry::{
surfaces::SweptCurve,
util::tri_mesh::{
convert_point_surface_to_global, convert_vector_surface_to_global,
},
Path, Tolerance,
};
#[test]
fn point_from_surface_coords() {
let surface = SweptCurve {
u: Path::Line(Line::from_origin_and_direction(
Point::from([1., 1., 1.]),
Vector::from([0., 2., 0.]),
)),
v: Vector::from([0., 0., 2.]),
};
// Value doesn't matter; we're dealing with a plane.
let tolerance = Tolerance::from_scalar(1.).unwrap();
assert_eq!(
convert_point_surface_to_global(&surface, [2., 4.], tolerance),
Point::from([1., 5., 9.]),
);
}
#[test]
fn vector_from_surface_coords() {
let surface = SweptCurve {
u: Path::Line(Line::from_origin_and_direction(
Point::from([1., 0., 0.]),
Vector::from([0., 2., 0.]),
)),
v: Vector::from([0., 0., 2.]),
};
// Value doesn't matter; we're dealing with a plane.
let tolerance = Tolerance::from_scalar(1.).unwrap();
assert_eq!(
convert_vector_surface_to_global(&surface, [2., 4.], tolerance),
Vector::from([0., 4., 8.]),
);
}
}