{"action":"created","issue":{"url":"https://api.github.com/repos/tonerdo/coverlet/issues/194","repository_url":"https://api.github.com/repos/tonerdo/coverlet","labels_url":"https://api.github.com/repos/tonerdo/coverlet/issues/194/labels{/name}","comments_url":"https://api.github.com/repos/tonerdo/coverlet/issues/194/comments","events_url":"https://api.github.com/repos/tonerdo/coverlet/issues/194/events","html_url":"https://github.com/tonerdo/coverlet/issues/194","id":362146876,"node_id":"MDU6SXNzdWUzNjIxNDY4NzY=","number":194,"title":"Compiler generated classes shown in the coverage result file","user":{"login":"LiangZugeng","id":20870130,"node_id":"MDQ6VXNlcjIwODcwMTMw","avatar_url":"https://avatars0.githubusercontent.com/u/20870130?v=4","gravatar_id":"","url":"https://api.github.com/users/LiangZugeng","html_url":"https://github.com/LiangZugeng","followers_url":"https://api.github.com/users/LiangZugeng/followers","following_url":"https://api.github.com/users/LiangZugeng/following{/other_user}","gists_url":"https://api.github.com/users/LiangZugeng/gists{/gist_id}","starred_url":"https://api.github.com/users/LiangZugeng/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LiangZugeng/subscriptions","organizations_url":"https://api.github.com/users/LiangZugeng/orgs","repos_url":"https://api.github.com/users/LiangZugeng/repos","events_url":"https://api.github.com/users/LiangZugeng/events{/privacy}","received_events_url":"https://api.github.com/users/LiangZugeng/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-09-20T11:37:43Z","updated_at":"2018-10-02T08:00:02Z","closed_at":null,"author_association":"NONE","body":"I use coverlet to analyze my .NET Core 2.1 app and it outputs cobertura format, then I use [report-generator](https://github.com/danielpalme/ReportGenerator) to convert the result file into HTML format for human reading, it's been using in our project for a while and I still haven't figured out some strange issues.\r\n\r\n1. I have a class called BlockController, in the coverage result file I found compiler generated classes shown in parallel with BlockController, see screenshot below. I wonder if coverlet can eliminate those classes and combine the coverage data with the actual BlockController.\r\n\r\n![image](https://user-images.githubusercontent.com/20870130/45815485-644f2b00-bd0b-11e8-8aff-dff99e2ca476.png)\r\n\r\n2. The method name has something as a suffix, take this `EaseSource.AnDa.SMT.Web.Controllers.BlockController/<GetAll>d__2`, what's the \"d__2\"?\r\n\r\n3. There is one aggregation level missing in the report, the coverage result of all methods in BlockController should be aggregated to BlockController to show the total coverage of this class, unfortunately this is not done, I guess it's because in the coverage result output file, the method coverage data is put in the <class> element, e.g.\r\n```\r\n        <class name=\"EaseSource.AnDa.SMT.Web.Controllers.BlockController/&lt;GetByIds&gt;d__5\" filename=\"Web\\Controllers\\BlockController.cs\" line-rate=\"1\" branch-rate=\"0.5\" complexity=\"0\">\r\n          <methods>\r\n            <method name=\"MoveNext\" signature=\"()\" line-rate=\"1\" branch-rate=\"0.5\">\r\n              <lines>\r\n                <line number=\"496\" hits=\"1\" branch=\"True\" condition-coverage=\"50% (1/2)\">\r\n                  <conditions>\r\n                    <condition number=\"343\" type=\"jump\" coverage=\"50%\" />\r\n                  </conditions>\r\n                </line>\r\n                <line number=\"497\" hits=\"1\" branch=\"False\" />\r\n                <line number=\"498\" hits=\"1\" branch=\"False\" />\r\n                <line number=\"499\" hits=\"1\" branch=\"False\" />\r\n                <line number=\"500\" hits=\"1\" branch=\"False\" />\r\n                <line number=\"501\" hits=\"1\" branch=\"False\" />\r\n                <line number=\"503\" hits=\"1\" branch=\"False\" />\r\n                <line number=\"504\" hits=\"1\" branch=\"False\" />\r\n              </lines>\r\n            </method>\r\n          </methods>\r\n          <lines>\r\n            <line number=\"496\" hits=\"1\" branch=\"True\" condition-coverage=\"50% (1/2)\">\r\n              <conditions>\r\n                <condition number=\"343\" type=\"jump\" coverage=\"50%\" />\r\n              </conditions>\r\n            </line>\r\n            <line number=\"497\" hits=\"1\" branch=\"False\" />\r\n            <line number=\"498\" hits=\"1\" branch=\"False\" />\r\n            <line number=\"499\" hits=\"1\" branch=\"False\" />\r\n            <line number=\"500\" hits=\"1\" branch=\"False\" />\r\n            <line number=\"501\" hits=\"1\" branch=\"False\" />\r\n            <line number=\"503\" hits=\"1\" branch=\"False\" />\r\n            <line number=\"504\" hits=\"1\" branch=\"False\" />\r\n          </lines>\r\n        </class>\r\n```\r\n\r\n\r\nThe output cobertura file for this class is also attached.\r\n[coverage.cobertura.xml.zip](https://github.com/tonerdo/coverlet/files/2401041/coverage.cobertura.xml.zip)\r\n\r\nPlease advice, thanks.\r\n"},"comment":{"url":"https://api.github.com/repos/tonerdo/coverlet/issues/comments/426184081","html_url":"https://github.com/tonerdo/coverlet/issues/194#issuecomment-426184081","issue_url":"https://api.github.com/repos/tonerdo/coverlet/issues/194","id":426184081,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNjE4NDA4MQ==","user":{"login":"Nysosis","id":5476382,"node_id":"MDQ6VXNlcjU0NzYzODI=","avatar_url":"https://avatars1.githubusercontent.com/u/5476382?v=4","gravatar_id":"","url":"https://api.github.com/users/Nysosis","html_url":"https://github.com/Nysosis","followers_url":"https://api.github.com/users/Nysosis/followers","following_url":"https://api.github.com/users/Nysosis/following{/other_user}","gists_url":"https://api.github.com/users/Nysosis/gists{/gist_id}","starred_url":"https://api.github.com/users/Nysosis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Nysosis/subscriptions","organizations_url":"https://api.github.com/users/Nysosis/orgs","repos_url":"https://api.github.com/users/Nysosis/repos","events_url":"https://api.github.com/users/Nysosis/events{/privacy}","received_events_url":"https://api.github.com/users/Nysosis/received_events","type":"User","site_admin":false},"created_at":"2018-10-02T08:00:02Z","updated_at":"2018-10-02T08:00:02Z","author_association":"NONE","body":"I've noticed this in my projects too, and seems to be occur everywhere that I'm using `async/await` tasks."}}
{"actor":{"display_login":"Nysosis"}}