public void CreateTraceSyndicationFeedTest() { SyndicationFeed actual = WcfTraceService_Accessor.CreateTraceSyndicationFeed(); Assert.IsNotNull(actual); Assert.IsTrue(actual.Title.Text == "WCF RIA Service Traces"); }
public void CreateTraceXmlTest() { Stream actual = WcfTraceService_Accessor.CreateTraceXml(); Assert.IsNotNull(actual); XElement root = XElement.Load(actual); Assert.IsTrue(root.Name.LocalName == "Traces"); }
public void CreateTraceSyndicationItemTest() { SyndicationItem actual = WcfTraceService_Accessor.CreateTraceSyndicationItem(this.CreateSampleTraceEntry()); Assert.IsNotNull(actual); Assert.IsTrue(actual.Title.Text == "Information: Security Impersonation succeeded at the server."); Assert.IsTrue(actual.PublishDate == new DateTimeOffset(634052379151696992, TimeSpan.Zero)); Assert.IsTrue(actual.LastUpdatedTime == actual.PublishDate); }
public void CreateTraceHtmlTest() { Stream actual = WcfTraceService_Accessor.CreateTraceHtml(); Assert.IsNotNull(actual); MemoryStream ms = new MemoryStream(); actual.CopyTo(ms); string html = Encoding.UTF8.GetString(ms.ToArray()); Assert.IsTrue(html.StartsWith("<html>", StringComparison.OrdinalIgnoreCase)); Assert.IsTrue(html.EndsWith("</html>", StringComparison.OrdinalIgnoreCase)); }