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

Function TEST

extensions/regex_ext_test.cc:77–93  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

75using LegacyActivation = google::api::expr::runtime::Activation;
76
77TEST(RegexExtTest, BuildFailsWithoutOptionalSupport) {
78 RuntimeOptions options;
79 options.enable_regex = true;
80 options.enable_qualified_type_identifiers = true;
81
82 ASSERT_OK_AND_ASSIGN(auto builder,
83 CreateStandardRuntimeBuilder(
84 internal::GetTestingDescriptorPool(), options));
85 ASSERT_THAT(
86 EnableReferenceResolver(builder, ReferenceResolverEnabled::kAlways),
87 IsOk());
88 // Optional types are NOT enabled.
89 ASSERT_THAT(RegisterRegexExtensionFunctions(builder),
90 StatusIs(absl::StatusCode::kInvalidArgument,
91 HasSubstr("regex extensions requires the optional types "
92 "to be enabled")));
93}
94
95TEST(RegexExtTest, LegacyRuntimeSmokeTest) {
96 InterpreterOptions options;

Callers

nothing calls this directly

Calls 12

EnableReferenceResolverFunction · 0.85
GetRegistryMethod · 0.80
ListOrDieMethod · 0.80
StringOrDieMethod · 0.80
IsListMethod · 0.45
sizeMethod · 0.45
IsStringMethod · 0.45
GetMethod · 0.45
valueMethod · 0.45
FindStaticOverloadsMethod · 0.45

Tested by

no test coverage detected