diff --git a/tests/geometry/isometry.rs b/tests/geometry/isometry.rs index 710c4ba9..6d48c6bf 100644 --- a/tests/geometry/isometry.rs +++ b/tests/geometry/isometry.rs @@ -75,13 +75,14 @@ quickcheck!( ) } + #[cfg_attr(rustfmt, rustfmt_skip)] fn composition2( i: Isometry2, uc: UnitComplex, r: Rotation2, t: Translation2, v: Vector2, - p: Point2, + p: Point2 ) -> bool { // (rotation × translation) * point = rotation × (translation * point) relative_eq!((uc * t) * v, uc * v, epsilon = 1.0e-7) && @@ -112,13 +113,14 @@ quickcheck!( relative_eq!((i * t) * p, i * (t * p), epsilon = 1.0e-7) } + #[cfg_attr(rustfmt, rustfmt_skip)] fn composition3( i: Isometry3, uq: UnitQuaternion, r: Rotation3, t: Translation3, v: Vector3, - p: Point3, + p: Point3 ) -> bool { // (rotation × translation) * point = rotation × (translation * point) relative_eq!((uq * t) * v, uq * v, epsilon = 1.0e-7) && @@ -149,13 +151,14 @@ quickcheck!( relative_eq!((i * t) * p, i * (t * p), epsilon = 1.0e-7) } + #[cfg_attr(rustfmt, rustfmt_skip)] fn all_op_exist( i: Isometry3, uq: UnitQuaternion, t: Translation3, v: Vector3, p: Point3, - r: Rotation3, + r: Rotation3 ) -> bool { let iMi = i * i; let iMuq = i * uq; diff --git a/tests/geometry/quaternion.rs b/tests/geometry/quaternion.rs index fdb88250..77456ca0 100644 --- a/tests/geometry/quaternion.rs +++ b/tests/geometry/quaternion.rs @@ -1,6 +1,5 @@ #![cfg(feature = "arbitrary")] #![allow(non_snake_case)] -#![cfg_attr(rustfmt, rustfmt_skip)] use na::{Point3, Quaternion, Rotation3, Unit, UnitQuaternion, Vector3}; @@ -56,12 +55,12 @@ quickcheck!( * */ + #[cfg_attr(rustfmt, rustfmt_skip)] fn unit_quaternion_transformation( q: UnitQuaternion, v: Vector3, p: Point3 - ) -> bool - { + ) -> bool { let r = q.to_rotation_matrix(); let rv = r * v; let rp = r * p; @@ -122,6 +121,7 @@ quickcheck!( // Test that all operators (incl. all combinations of references) work. // See the top comment on `geometry/quaternion_ops.rs` for details on which operations are // supported. + #[cfg_attr(rustfmt, rustfmt_skip)] fn all_op_exist( q: Quaternion, uq: UnitQuaternion, @@ -129,8 +129,7 @@ quickcheck!( p: Point3, r: Rotation3, s: f64 - ) -> bool - { + ) -> bool { let uv = Unit::new_normalize(v); let qpq = q + q; diff --git a/tests/geometry/similarity.rs b/tests/geometry/similarity.rs index e8e417ef..b93d2e51 100644 --- a/tests/geometry/similarity.rs +++ b/tests/geometry/similarity.rs @@ -15,10 +15,11 @@ quickcheck!( && relative_eq!((ii * i) * v, v, epsilon = 1.0e-7) } + #[cfg_attr(rustfmt, rustfmt_skip)] fn inverse_is_parts_inversion( t: Translation3, r: UnitQuaternion, - scaling: f64, + scaling: f64 ) -> bool { if relative_eq!(scaling, 0.0) { true @@ -28,10 +29,11 @@ quickcheck!( } } + #[cfg_attr(rustfmt, rustfmt_skip)] fn multiply_equals_alga_transform( s: Similarity3, v: Vector3, - p: Point3, + p: Point3 ) -> bool { s * v == s.transform_vector(&v) && s * p == s.transform_point(&p) @@ -47,13 +49,14 @@ quickcheck!( ) } + #[cfg_attr(rustfmt, rustfmt_skip)] fn composition( i: Isometry3, uq: UnitQuaternion, t: Translation3, v: Vector3, p: Point3, - scaling: f64, + scaling: f64 ) -> bool { if relative_eq!(scaling, 0.0) { return true; @@ -142,13 +145,14 @@ quickcheck!( relative_eq!((s * i * t) * p, scaling * (i * (t * p)), epsilon = 1.0e-7) } + #[cfg_attr(rustfmt, rustfmt_skip)] fn all_op_exist( s: Similarity3, i: Isometry3, uq: UnitQuaternion, t: Translation3, v: Vector3, - p: Point3, + p: Point3 ) -> bool { let sMs = s * s; let sMuq = s * uq; diff --git a/tests/geometry/unit_complex.rs b/tests/geometry/unit_complex.rs index 37af38f9..263ecd33 100644 --- a/tests/geometry/unit_complex.rs +++ b/tests/geometry/unit_complex.rs @@ -68,11 +68,12 @@ quickcheck!( // Test that all operators (incl. all combinations of references) work. // See the top comment on `geometry/quaternion_ops.rs` for details on which operations are // supported. + #[cfg_attr(rustfmt, rustfmt_skip)] fn all_op_exist( uc: UnitComplex, v: Vector2, p: Point2, - r: Rotation2, + r: Rotation2 ) -> bool { let uv = Unit::new_normalize(v);