public void ToString_EscapeSequences() { // Arrange var stringNode = new JsonStringNode("Hello\r\n\tWorld!"); // Act string result = stringNode.ToString(); // Assert Assert.AreEqual("\"Hello\\r\\n\\tWorld!\"", result); }
public void ToString_Null() { // Arrange var stringNode = new JsonStringNode(null); // Act string result = stringNode.ToString(); // Assert Assert.AreEqual("\"\"", result); }
public void ToString_SimpleCharacters() { // Arrange var stringNode = new JsonStringNode("Hello World!"); // Act string result = stringNode.ToString(); // Assert Assert.AreEqual("\"Hello World!\"", result); }