viirya commented on code in PR #5123:
URL: https://github.com/apache/arrow-rs/pull/5123#discussion_r1404702004


##########
arrow-cast/src/cast.rs:
##########
@@ -4719,6 +4726,35 @@ mod tests {
         assert_eq!(&actual, &expected);
     }
 
+    #[test]
+    fn test_cast_floating_to_timestamp() {
+        let array = Int64Array::from(vec![Some(2), Some(10), None]);
+        let expected = cast(&array, 
&DataType::Timestamp(TimeUnit::Microsecond, None)).unwrap();
+
+        let array = Float32Array::from(vec![Some(2.0), Some(10.6), None]);

Review Comment:
   I don't add test for Float16Array as casting between Float16 and Int64 is 
not supported by cast kernel now. I will make it in a separate PR later.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to