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

Function TEST_F

cpp/src/arrow/compute/util_internal_test.cc:40–49  ·  view source on GitHub ↗

GH-41738: Test the underlying buffer capacity is sufficient to hold the requested vector.

Source from the content-addressed store, hash-verified

38// GH-41738: Test the underlying buffer capacity is sufficient to hold the requested
39// vector.
40TEST_F(TempVectorStackTest, BufferCapacitySufficiency) {
41 for (uint32_t stack_size : {1, 7, 8, 63, 64, 65535, 65536}) {
42 ARROW_SCOPED_TRACE("stack_size = ", stack_size);
43 TempVectorStack stack;
44 ASSERT_OK(stack.Init(default_memory_pool(), stack_size));
45
46 TempVectorHolder<uint8_t> v(&stack, stack_size);
47 ASSERT_LE(v.mutable_data() + stack_size, BufferData(stack) + BufferCapacity(stack));
48 }
49}
50
51} // namespace util
52} // namespace arrow

Callers

nothing calls this directly

Calls 3

default_memory_poolFunction · 0.85
InitMethod · 0.45
mutable_dataMethod · 0.45

Tested by

no test coverage detected