MCPcopy Create free account
hub / github.com/awslabs/aws-lambda-cpp / OutputXmlAttribute

Method OutputXmlAttribute

tests/gtest/gtest-all.cc:5217–5231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5215}
5216
5217void XmlUnitTestResultPrinter::OutputXmlAttribute(
5218 std::ostream* stream,
5219 const std::string& element_name,
5220 const std::string& name,
5221 const std::string& value) {
5222 const std::vector<std::string>& allowed_names =
5223 GetReservedOutputAttributesForElement(element_name);
5224
5225 GTEST_CHECK_(std::find(allowed_names.begin(), allowed_names.end(), name) !=
5226 allowed_names.end())
5227 << "Attribute " << name << " is not allowed for element <" << element_name
5228 << ">.";
5229
5230 *stream << " " << name << "=\"" << EscapeXmlAttribute(value) << "\"";
5231}
5232
5233// Prints an XML representation of a TestInfo object.
5234void XmlUnitTestResultPrinter::OutputXmlTestInfo(::std::ostream* stream,

Callers

nothing calls this directly

Calls 3

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected