Fix tests for nalgebra-sparse.

This commit is contained in:
Crozet Sébastien 2021-03-01 12:42:44 +01:00
parent 258ecf22bc
commit 80aa4faa38
1 changed files with 2 additions and 2 deletions

View File

@ -108,8 +108,8 @@ where
// NOTE: The below line is the whole reason for the existence of this adapted code // NOTE: The below line is the whole reason for the existence of this adapted code
// We need to be able to swap with the same element, so that some elements remain in // We need to be able to swap with the same element, so that some elements remain in
// place rather being swapped // place rather being swapped
// let end_index = rng.gen_range(start_index + 1, len); // let end_index = rng.gen_range(start_index + 1..len);
let end_index = rng.gen_range(start_index, len); let end_index = rng.gen_range(start_index..len);
if end_index - start_index <= max_swap { if end_index - start_index <= max_swap {
value.shuffle_swap(start_index, end_index); value.shuffle_swap(start_index, end_index);
} }