Skip to content

Commit

Permalink
Restored test with nulls.
Browse files Browse the repository at this point in the history
  • Loading branch information
paddyhoran committed Jan 25, 2019
1 parent 545ee25 commit d7908bd
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions rust/arrow/src/compute/arithmetic_kernels.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,15 +126,15 @@ mod tests {
);
}

// #[test]
// fn test_primitive_array_add_with_nulls() {
// let a = Int32Array::from(vec![Some(5), None, Some(7), None]);
// let b = Int32Array::from(vec![None, None, Some(6), Some(7)]);
// let c = add(&a, &b).unwrap();
// assert_eq!(true, c.is_null(0));
// assert_eq!(true, c.is_null(1));
// assert_eq!(false, c.is_null(2));
// assert_eq!(true, c.is_null(3));
// assert_eq!(13, c.value(2));
// }
#[test]
fn test_primitive_array_add_with_nulls() {
let a = Int32Array::from(vec![Some(5), None, Some(7), None]);
let b = Int32Array::from(vec![None, None, Some(6), Some(7)]);
let c = add(&a, &b).unwrap();
assert_eq!(true, c.is_null(0));
assert_eq!(true, c.is_null(1));
assert_eq!(false, c.is_null(2));
assert_eq!(true, c.is_null(3));
assert_eq!(13, c.value(2));
}
}

0 comments on commit d7908bd

Please sign in to comment.