From 87a80c2de60ef490c743d201d82e5bd1a7122101 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Crozet?= Date: Thu, 24 Mar 2016 19:03:57 +0100 Subject: [PATCH] Fix tests. --- src/structs/vecn_macros.rs | 4 ++-- tests/vec.rs | 27 +-------------------------- 2 files changed, 3 insertions(+), 28 deletions(-) diff --git a/src/structs/vecn_macros.rs b/src/structs/vecn_macros.rs index b874cc37..c4bd8945 100644 --- a/src/structs/vecn_macros.rs +++ b/src/structs/vecn_macros.rs @@ -13,7 +13,7 @@ macro_rules! vecn_dvec_common_impl( impl)*> AsRef<[N]> for $vecn { #[inline] fn as_ref(&self) -> &[N] { - &self[.. self.len()] + &self.at[.. self.len()] } } @@ -21,7 +21,7 @@ macro_rules! vecn_dvec_common_impl( #[inline] fn as_mut(&mut self) -> &mut [N] { let len = self.len(); - &mut self[.. len] + &mut self.at[.. len] } } diff --git a/tests/vec.rs b/tests/vec.rs index 48d3656a..bd97361f 100644 --- a/tests/vec.rs +++ b/tests/vec.rs @@ -4,7 +4,7 @@ extern crate nalgebra as na; use rand::random; use typenum::U10; -use na::{VecN, Vec0, Vec1, Vec2, Vec3, Vec4, Vec5, Vec6, Mat3, Rot2, Rot3, Iterable, IterableMut}; +use na::{VecN, Vec1, Vec2, Vec3, Vec4, Vec5, Vec6, Mat3, Rot2, Rot3, Iterable, IterableMut}; macro_rules! test_iterator_impl( ($t: ty, $n: ty) => ( @@ -112,11 +112,6 @@ fn test_cross_vec3() { } } -#[test] -fn test_commut_dot_vec0() { - test_commut_dot_impl!(Vec0); -} - #[test] fn test_commut_dot_vec1() { test_commut_dot_impl!(Vec1); @@ -147,11 +142,6 @@ fn test_commut_dot_vec6() { test_commut_dot_impl!(Vec6); } -#[test] -fn test_basis_vec0() { - test_basis_impl!(Vec0); -} - #[test] fn test_basis_vec1() { test_basis_impl!(Vec1); @@ -182,11 +172,6 @@ fn test_basis_vec6() { test_basis_impl!(Vec6); } -#[test] -fn test_subspace_basis_vec0() { - test_subspace_basis_impl!(Vec0); -} - #[test] fn test_subspace_basis_vec1() { test_subspace_basis_impl!(Vec1); @@ -217,11 +202,6 @@ fn test_subspace_basis_vec6() { test_subspace_basis_impl!(Vec6); } -#[test] -fn test_scalar_op_vec0() { - test_scalar_op_impl!(Vec0, f64); -} - #[test] fn test_scalar_op_vec1() { test_scalar_op_impl!(Vec1, f64); @@ -252,11 +232,6 @@ fn test_scalar_op_vec6() { test_scalar_op_impl!(Vec6, f64); } -#[test] -fn test_iterator_vec0() { - test_iterator_impl!(Vec0, f64); -} - #[test] fn test_iterator_vec1() { test_iterator_impl!(Vec1, f64);