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

Function TEST

common/ast/expr_proto_test.cc:254–274  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

252 }));
253
254TEST(ExprFromProto, StructFieldInMap) {
255 ExprProto original_proto;
256 ASSERT_TRUE(
257 google::protobuf::TextFormat::ParseFromString(R"pb(
258 id: 1
259 struct_expr: {
260 entries: {
261 id: 2
262 field_key: "foo"
263 value: {
264 id: 3
265 ident_expr: { name: "bar" }
266 }
267 }
268 }
269 )pb",
270 &original_proto));
271 Expr expr;
272 ASSERT_THAT(ExprFromProto(original_proto, expr),
273 StatusIs(absl::StatusCode::kInvalidArgument));
274}
275
276TEST(ExprFromProto, MapEntryInStruct) {
277 ExprProto original_proto;

Callers

nothing calls this directly

Calls 1

ExprFromProtoFunction · 0.85

Tested by

no test coverage detected