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

Function TEST_F

bolt/expression/tests/FunctionCallToSpecialFormTest.cpp:57–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55};
56
57TEST_F(FunctionCallToSpecialFormTest, andCall) {
58 ASSERT_TRUE(isFunctionCallToSpecialFormRegistered("and"));
59
60 auto type = resolveTypeForSpecialForm("and", {BOOLEAN(), BOOLEAN()});
61 ASSERT_EQ(type, BOOLEAN());
62
63 auto specialForm = constructSpecialForm(
64 "and",
65 BOOLEAN(),
66 {std::make_shared<ConstantExpr>(
67 vectorMaker_.constantVector<bool>({true})),
68 std::make_shared<ConstantExpr>(
69 vectorMaker_.constantVector<bool>({false}))},
70 false,
71 config_);
72 ASSERT_EQ(typeid(*specialForm), typeid(const ConjunctExpr&));
73}
74
75TEST_F(FunctionCallToSpecialFormTest, castCall) {
76 ASSERT_TRUE(isFunctionCallToSpecialFormRegistered("cast"));

Callers

nothing calls this directly

Calls 3

constructSpecialFormFunction · 0.85

Tested by

no test coverage detected