MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / TEST

Function TEST

tensorflow/core/framework/op_gen_lib_test.cc:73–142  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71)";
72
73TEST(OpGenLibTest, MultilinePBTxt) {
74 // Non-multiline pbtxt
75 const string pbtxt = R"(foo: "abc"
76foo: ""
77foo: "\n\n"
78foo: "abc\nEND"
79 foo: "ghi\njkl\n"
80bar: "quotes:\""
81)";
82
83 // Field "foo" converted to multiline but not "bar".
84 const string ml_foo = R"(foo: <<END
85abc
86END
87foo: <<END
88
89END
90foo: <<END
91
92
93
94END
95foo: <<END0
96abc
97END
98END0
99 foo: <<END
100ghi
101jkl
102
103END
104bar: "quotes:\""
105)";
106
107 // Both fields "foo" and "bar" converted to multiline.
108 const string ml_foo_bar = R"(foo: <<END
109abc
110END
111foo: <<END
112
113END
114foo: <<END
115
116
117
118END
119foo: <<END0
120abc
121END
122END0
123 foo: <<END
124ghi
125jkl
126
127END
128bar: <<END
129quotes:"
130END

Callers

nothing calls this directly

Calls 12

PBTxtToMultilineFunction · 0.85
PBTxtFromMultilineFunction · 0.85
GetApiDefMethod · 0.80
LoadApiDefMethod · 0.80
descriptionMethod · 0.80
UpdateDocsMethod · 0.80
attrMethod · 0.80
nameMethod · 0.65
DebugStringMethod · 0.45
add_opMethod · 0.45
summaryMethod · 0.45
codeMethod · 0.45

Tested by

no test coverage detected