MCPcopy Create free account
hub / github.com/apache/arrow / test_dictionary_from_buffers

Function test_dictionary_from_buffers

python/pyarrow/tests/test_array.py:982–987  ·  view source on GitHub ↗
(offset)

Source from the content-addressed store, hash-verified

980
981@pytest.mark.parametrize("offset", (0, 1))
982def test_dictionary_from_buffers(offset):
983 a = pa.array(["one", "two", "three", "two", "one"]).dictionary_encode()
984 b = pa.DictionaryArray.from_buffers(a.type, len(a)-offset,
985 a.indices.buffers(), a.dictionary,
986 offset=offset)
987 assert a[offset:] == b
988
989
990@pytest.mark.numpy

Callers

nothing calls this directly

Calls 3

lenFunction · 0.85
buffersMethod · 0.80
arrayMethod · 0.45

Tested by

no test coverage detected