MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / TEST_F

Function TEST_F

tests/src/Base/Writer.cpp:21–32  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19};
20
21TEST_F(WriterTest, insertTextSimple)
22{
23 // Arrange
24 std::string testTextData {"Simple ASCII data"};
25 std::string expectedResult {"<![CDATA[" + testTextData + "]]>"};
26
27 // Act
28 _writer.insertText(testTextData);
29
30 // Assert
31 EXPECT_EQ(expectedResult, _writer.getString());
32}
33
34/// If the data happens to actually include an XML CDATA close marker, that needs to be "escaped" --
35/// this is done by breaking it up into two separate CDATA sections, splitting apart the marker.

Callers

nothing calls this directly

Calls 3

insertTextMethod · 0.80
endCharStreamMethod · 0.80
getStringMethod · 0.45

Tested by

no test coverage detected