()
| 114 | |
| 115 | #[test] |
| 116 | fn clamp() { |
| 117 | let new_vector = vector3::Vector3 { |
| 118 | x: 3.0, |
| 119 | y: 4.0, |
| 120 | z: 5.0, |
| 121 | }; |
| 122 | let tar_vector = vector3::Vector3 { |
| 123 | x: 3.0, |
| 124 | y: 3.0, |
| 125 | z: 3.0, |
| 126 | }; |
| 127 | let res_vector = new_vector.clamp(0.0, 3.0); |
| 128 | assert_vector3_approx_eq(&tar_vector, &res_vector); |
| 129 | } |
| 130 | |
| 131 | #[test] |
| 132 | fn project_on_to() { |
nothing calls this directly
no test coverage detected