Skip to content

Commit c987a80

Browse files
committed
Fix Wasm tests failing
1 parent 4e55346 commit c987a80

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/linear/logistic_regression.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -829,7 +829,7 @@ mod tests {
829829
#[test]
830830
#[cfg(feature = "serde")]
831831
fn serde() {
832-
let x: DenseMatrix<f32> = DenseMatrix::from_2d_array(&[
832+
let x: DenseMatrix<f64> = DenseMatrix::from_2d_array(&[
833833
&[1., -5.],
834834
&[2., 5.],
835835
&[3., -2.],
@@ -845,7 +845,7 @@ mod tests {
845845
&[10., -2.],
846846
&[8., 2.],
847847
&[9., 0.],
848-
]);
848+
]).unwrap();
849849
let y: Vec<i32> = vec![0, 0, 1, 1, 2, 1, 1, 0, 0, 2, 1, 1, 0, 0, 1];
850850

851851
let lr = LogisticRegression::fit(&x, &y, Default::default()).unwrap();

src/readers/csv.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ mod tests {
266266
&[5.1, 3.5, 1.4, 0.2],
267267
&[4.9, 3.0, 1.4, 0.2],
268268
&[4.7, 3.2, 1.3, 0.2],
269-
]))
269+
]).unwrap())
270270
)
271271
}
272272
#[test]

0 commit comments

Comments
 (0)