public void TestMixedContent() { var elem = new SsmlPhoneme(); elem.AddText("before") .AddChild("Child").AddText("content"); elem.AddText("after"); Assert.AreEqual( "<?xml version=\"1.0\" encoding=\"utf-8\"?>" + Environment.NewLine + "<phoneme>before<Child>content</Child>after</phoneme>", elem.ToString() ); }
public void TestElementWithTextNode() { var elem = new SsmlPhoneme(); elem.AddText("Here is the content"); Assert.AreEqual( "<?xml version=\"1.0\" encoding=\"utf-8\"?>" + Environment.NewLine + "<phoneme>Here is the content</phoneme>", elem.ToString() ); }