MCPcopy Create free account
hub / github.com/Samsung/UTopia / getTCCall

Method getTCCall

lib/tcanalysis/BoostCallWriter.cpp:6–22  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4using namespace ftg;
5
6std::string BoostCallWriter::getTCCall(const Unittest &TC,
7 std::string Indent) const {
8 const std::string InstanceName = "Fuzzer";
9
10 const auto *TCTestBody = TC.getTestBody();
11 if (!TCTestBody)
12 return "";
13
14 auto StructName = TCTestBody->getClassName();
15 if (StructName.empty())
16 return "";
17
18 return Indent + "try {\n" + Indent + util::getIndent(1) + "struct " +
19 StructName + " " + InstanceName + ";\n" + Indent + util::getIndent(1) +
20 InstanceName + ".test_method();\n" + Indent +
21 "} catch (std::exception &E) {}\n";
22}

Callers

nothing calls this directly

Calls 4

getIndentFunction · 0.85
getClassNameMethod · 0.80
emptyMethod · 0.80
getTestBodyMethod · 0.45

Tested by

no test coverage detected