mirror of
https://github.com/Magnus167/rustframe.git
synced 2025-08-21 03:49:59 +00:00
Compare commits
1 Commits
d57ad43a57
...
f0b27299d1
Author | SHA1 | Date | |
---|---|---|---|
![]() |
f0b27299d1 |
@ -1205,21 +1205,6 @@ mod tests {
|
|||||||
assert_eq!(ma.row(1), &[10, 20, 30]);
|
assert_eq!(ma.row(1), &[10, 20, 30]);
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
|
||||||
#[should_panic(expected = "row index 3 out of bounds for 3 rows")]
|
|
||||||
fn test_row_out_of_bounds_index() {
|
|
||||||
let ma = static_test_matrix();
|
|
||||||
ma.row(3);
|
|
||||||
}
|
|
||||||
|
|
||||||
#[test]
|
|
||||||
#[should_panic(expected = "input slice length 2 does not match number of columns 3")]
|
|
||||||
fn test_row_copy_from_slice_wrong_length() {
|
|
||||||
let mut ma = static_test_matrix();
|
|
||||||
let new_row = vec![10, 20]; // Only 2 elements, but row length is 3
|
|
||||||
ma.row_copy_from_slice(1, &new_row);
|
|
||||||
}
|
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn test_shape() {
|
fn test_shape() {
|
||||||
let ma = static_test_matrix_2x4();
|
let ma = static_test_matrix_2x4();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user