| 48 | }; |
| 49 | |
| 50 | TEST_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 | |
| 73 | TEST_F(EvalCtxTest, vectorPool) { |
| 74 | EvalCtx context(&execCtx_); |
nothing calls this directly
no test coverage detected