MCPcopy Create free account
hub / github.com/apache/impala / TEST

Function TEST

be/src/kudu/util/bitmap-test.cc:42–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

40}
41
42TEST(TestBitMap, TestIteration) {
43 uint8_t bm[8];
44 memset(bm, 0, sizeof(bm));
45 BitmapSet(bm, 0);
46 BitmapSet(bm, 8);
47 BitmapSet(bm, 31);
48 BitmapSet(bm, 32);
49 BitmapSet(bm, 33);
50 BitmapSet(bm, 63);
51
52 EXPECT_EQ(" 0: 10000000 10000000 00000000 00000001 11000000 00000000 00000000 00000001 \n",
53 BitmapToString(bm, sizeof(bm) * 8));
54
55 std::vector<size_t> read_back;
56
57 ReadBackBitmap(bm, sizeof(bm)*8, &read_back);
58 ASSERT_EQ("0,8,31,32,33,63", JoinElements(read_back, ","));
59}
60
61
62TEST(TestBitMap, TestIteration2) {

Callers

nothing calls this directly

Calls 15

BitmapSetFunction · 0.85
BitmapToStringFunction · 0.85
ReadBackBitmapFunction · 0.85
JoinElementsFunction · 0.85
GetRandomSeed32Function · 0.85
ForEachSetBitFunction · 0.85
BitmapTestFunction · 0.85
BitmapClearFunction · 0.85
BitmapChangeFunction · 0.85
BitmapChangeBitsFunction · 0.85
BitmapIsAllSetFunction · 0.85
BitmapIsAllZeroFunction · 0.85

Tested by

no test coverage detected