MCPcopy Create free account
hub / github.com/cel-expr/cel-cpp / CompileForTestCase

Function CompileForTestCase

extensions/select_optimization_test.cc:225–233  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

223}
224
225absl::StatusOr<std::unique_ptr<cel::Ast>> CompileForTestCase(
226 absl::string_view expr) {
227 CEL_ASSIGN_OR_RETURN(cel::ValidationResult r,
228 TestCaseCompiler().Compile(expr));
229 if (!r.IsValid()) {
230 return absl::InvalidArgumentError(r.FormatError());
231 }
232 return r.ReleaseAst();
233}
234
235class MockAccessApis : public LegacyTypeInfoApis, public LegacyTypeAccessApis {
236 public:

Callers 2

TEST_FFunction · 0.85
TEST_PFunction · 0.85

Calls 3

IsValidMethod · 0.80
FormatErrorMethod · 0.80
ReleaseAstMethod · 0.80

Tested by

no test coverage detected