MCPcopy Create free account
hub / github.com/bytedance/bolt / TEST_F

Function TEST_F

bolt/expression/tests/EvalCtxTest.cpp:50–71  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

48};
49
50TEST_F(EvalCtxTest, selectivityVectors) {
51 EvalCtx context(&execCtx_);
52 SelectivityVector all100(100, true);
53 SelectivityVector none100(100, false);
54
55 // Not initialized, initially nullptr.
56 LocalSelectivityVector local1(context);
57 EXPECT_TRUE(!local1.get());
58
59 // Specify initialization in get()
60 EXPECT_EQ(all100, *local1.get(100, true));
61
62 // The get() stays the same.
63 EXPECT_EQ(all100, *local1.get());
64
65 // Initialize from other in get().
66 EXPECT_EQ(none100, *local1.get(none100));
67
68 // Init from existing
69 LocalSelectivityVector local2(context, all100);
70 EXPECT_EQ(all100, *local2.get());
71}
72
73TEST_F(EvalCtxTest, vectorPool) {
74 EvalCtx context(&execCtx_);

Callers

nothing calls this directly

Calls 15

releaseVectorMethod · 0.80
vectorPoolMethod · 0.80
errorsPtrMethod · 0.80
mutableThrowOnErrorMethod · 0.80
setErrorsMethod · 0.80
addErrorMethod · 0.80
addErrorsMethod · 0.80
countSelectedMethod · 0.80
isValidMethod · 0.80
countNullsFunction · 0.50
getMethod · 0.45

Tested by

no test coverage detected