MCPcopy Create free account
hub / github.com/apache/arrow-rs / bit_length_offsets_string

Function bit_length_offsets_string

arrow-string/src/length.rs:709–717  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

707 /// Tests with an offset
708 #[test]
709 fn bit_length_offsets_string() {
710 let a = StringArray::from(vec![Some("hello"), Some(" "), Some("world"), None]);
711 let b = a.slice(1, 3);
712 let result = bit_length(&b).unwrap();
713 let result: &Int32Array = result.as_primitive();
714
715 let expected = Int32Array::from(vec![Some(8), Some(40), None]);
716 assert_eq!(&expected, result);
717 }
718
719 #[test]
720 fn bit_length_offsets_binary() {

Callers

nothing calls this directly

Calls 3

bit_lengthFunction · 0.85
as_primitiveMethod · 0.80
sliceMethod · 0.45

Tested by

no test coverage detected