MCPcopy Create free account
hub / github.com/apache/datafusion / test_create_hashes_from_arrays

Function test_create_hashes_from_arrays

datafusion/common/src/hash_utils.rs:1764–1774  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1762
1763 #[test]
1764 fn test_create_hashes_from_arrays() {
1765 let int_array: ArrayRef = Arc::new(Int32Array::from(vec![1, 2, 3, 4]));
1766 let float_array: ArrayRef =
1767 Arc::new(Float64Array::from(vec![1.0, 2.0, 3.0, 4.0]));
1768
1769 let random_state = RandomState::with_seed(0);
1770 let hashes_buff = &mut vec![0; int_array.len()];
1771 let hashes =
1772 create_hashes(&[int_array, float_array], &random_state, hashes_buff).unwrap();
1773 assert_eq!(hashes.len(), 4,);
1774 }
1775
1776 #[test]
1777 fn test_create_hashes_from_dyn_arrays() {

Callers

nothing calls this directly

Calls 2

newFunction · 0.85
create_hashesFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…