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

Function TestQuotedString

internal/strings_test.cc:45–49  ·  view source on GitHub ↗

takes a string literal of the form '...', r'...', "..." or r"...". is the expected parsed form of .

Source from the content-addressed store, hash-verified

43// <quoted> takes a string literal of the form '...', r'...', "..." or r"...".
44// <unquoted> is the expected parsed form of <quoted>.
45void TestQuotedString(const std::string& unquoted, const std::string& quoted) {
46 auto status_or_unquoted = ParseStringLiteral(quoted);
47 EXPECT_OK(status_or_unquoted) << unquoted;
48 EXPECT_EQ(unquoted, status_or_unquoted.value()) << quoted;
49}
50
51void TestString(const std::string& unquoted) {
52 TestQuotedString(unquoted, FormatStringLiteral(unquoted));

Callers 2

TestStringFunction · 0.85
TestRawStringFunction · 0.85

Calls 2

ParseStringLiteralFunction · 0.85
valueMethod · 0.45

Tested by

no test coverage detected