|
|
|
|
@ -29,18 +29,35 @@ namespace ICSharpCode.CodeCoverage.Tests.Highlighting
@@ -29,18 +29,35 @@ namespace ICSharpCode.CodeCoverage.Tests.Highlighting
|
|
|
|
|
ITextMarkerService markerStrategy = document.GetService(typeof(ITextMarkerService)) as ITextMarkerService; |
|
|
|
|
document.Text = "abcdefg\r\nabc"; |
|
|
|
|
|
|
|
|
|
string xml = "<PartCoverReport>\r\n" + |
|
|
|
|
"\t<File id=\"1\" url=\"c:\\Projects\\XmlEditor\\Test\\Schema\\SingleElementSchemaTestFixture.cs\" />\r\n" + |
|
|
|
|
"\t<Assembly id=\"1\" name=\"XmlEditor.Tests\" module=\"C:\\Projects\\Test\\XmlEditor.Tests\\bin\\XmlEditor.Tests.DLL\" domain=\"test-domain-XmlEditor.Tests.dll\" domainIdx=\"1\" />\r\n" + |
|
|
|
|
"\t<Type name=\"XmlEditor.Tests.Schema.SingleElementSchemaTestFixture\" asmref=\"1\">\r\n" + |
|
|
|
|
"\t\t<Method name=\"GetSchema\">\r\n" + |
|
|
|
|
"\t\t<pt visit=\"1\" fid=\"1\" sl=\"1\" sc=\"1\" el=\"1\" ec=\"9\"/>\r\n" + |
|
|
|
|
"\t\t<pt visit=\"1\" fid=\"1\" sl=\"1\" sc=\"1\" el=\"1\" ec=\"0\" />\r\n" + |
|
|
|
|
"\t\t<pt visit=\"1\" fid=\"1\" sl=\"1\" sc=\"1\" el=\"1\" ec=\"-1\" />\r\n" + |
|
|
|
|
"\t\t<pt visit=\"1\" fid=\"1\" sl=\"1\" sc=\"3\" el=\"1\" ec=\"2\" />\r\n" + |
|
|
|
|
"\t\t</Method>\r\n" + |
|
|
|
|
"\t</Type>\r\n" + |
|
|
|
|
"</PartCoverReport>"; |
|
|
|
|
string xml = "<CoverageSession xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\r\n" + |
|
|
|
|
"\t<Modules>\r\n" + |
|
|
|
|
"\t\t<Module hash=\"44-54-B6-13-97-49-45-F8-6A-74-9E-49-0C-77-87-C6-9C-54-47-7A\">\r\n" + |
|
|
|
|
"\t\t\t<FullName>C:\\Projects\\Test\\Foo.Tests\\bin\\Foo.Tests.DLL</FullName>\r\n" + |
|
|
|
|
"\t\t\t<ModuleName>Foo.Tests</ModuleName>\r\n" + |
|
|
|
|
"\t\t\t<Files>\r\n" + |
|
|
|
|
"\t\t\t\t<File uid=\"1\" fullPath=\"c:\\Projects\\Foo\\FooTestFixture.cs\" />\r\n" + |
|
|
|
|
"\t\t\t</Files>\r\n" + |
|
|
|
|
"\t\t\t<Classes>\r\n" + |
|
|
|
|
"\t\t\t\t<Class>\r\n" + |
|
|
|
|
"\t\t\t\t\t<FullName>Foo.Tests.FooTestFixture</FullName>\r\n" + |
|
|
|
|
"\t\t\t\t\t<Methods>\r\n" + |
|
|
|
|
"\t\t\t\t\t\t<Method visited=\"true\" cyclomaticComplexity=\"1\" sequenceCoverage=\"100\" branchCoverage=\"100\" isConstructor=\"false\" isStatic=\"false\" isGetter=\"false\" isSetter=\"false\">\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t<MetadataToken>100663297</MetadataToken>\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t<Name>System.Void Foo.Tests.FooTestFixture::SimpleTest()</Name>\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t<FileRef uid=\"1\" />\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t<SequencePoints>\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t\t<SequencePoint vc=\"1\" sl=\"1\" sc=\"1\" el=\"1\" ec=\"9\" />\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t\t<SequencePoint vc=\"1\" sl=\"1\" sc=\"1\" el=\"1\" ec=\"0\" />\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t\t<SequencePoint vc=\"1\" sl=\"1\" sc=\"1\" el=\"1\" ec=\"-1\" />\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t\t<SequencePoint vc=\"1\" sl=\"1\" sc=\"3\" el=\"1\" ec=\"2\" />\r\n" + |
|
|
|
|
"\t\t\t\t\t\t\t</SequencePoints>\r\n" + |
|
|
|
|
"\t\t\t\t\t\t</Method>\r\n" + |
|
|
|
|
"\t\t\t\t\t</Methods>\r\n" + |
|
|
|
|
"\t\t\t\t</Class>\r\n" + |
|
|
|
|
"\t\t\t</Classes>\r\n" + |
|
|
|
|
"\t\t</Module>\r\n" + |
|
|
|
|
"\t</Modules>\r\n" + |
|
|
|
|
"</CoverageSession>"; |
|
|
|
|
|
|
|
|
|
CodeCoverageResults results = new CodeCoverageResults(new StringReader(xml)); |
|
|
|
|
CodeCoverageMethod method = results.Modules[0].Methods[0]; |
|
|
|
|
|