angelozerr / angular-eclipse

Angular Eclipse Plugin
https://angular.io/
Eclipse Public License 1.0
69 stars 12 forks source link

Provide code coverage information for unit test (or e2e test) execution #27

Open PMJMendes opened 8 years ago

PMJMendes commented 8 years ago

Provide source highliting (like EclEmma) after test execution according to which source lines and branches were executed during the test batch.

angelozerr commented 8 years ago

I think it's a big work. Perhaps we could start to provide a JUnit View like? I don't know if it's possible to do that. I must study result of test (never played with ng test).

angelozerr commented 7 years ago

@PMJMendes I tell me if it's a really interesting feature since https://github.com/angul ar/angular-cli/wiki/test provides the capability to generate HTML pages with coverage.

When you execute:

ng test --code-coverage

You can generate report like

image

PMJMendes commented 7 years ago

Hello,

From: Angelo [mailto:notifications@github.com]

@PMJMendeshttps://github.com/PMJMendes I tell me if it's a really interesting feature since

https://github.com/angular/angular-cli/wiki/test provides the capability to generate HTML pages with coverage ?

Hmmm, good call. I haven’t checked out the coverage HTML pages yet. If they work well, I guess it’s not as important a feature as it would be without them. Having the code colored directly in the editor is helpful, so I guess it’s probably still interesting, but just as a nice-to-have…

Cheers, J.

probert94 commented 7 years ago

@angelozerr @PMJMendes I just created an Issue in typescript.java (See angelozerr/typescript.java#175), since this should be solved for typescript in general, not only for angular (in my opinion).
As you said, it will be pretty complex, but after a quick investiagation, it does not seem impossible to me.
There is already an Eclipse-implementation for code coverage in java and karma supports different coverage reporters, which results we could use.
Since there are already pretty cool reporters for karma (like the HTML-Reporter shown above), I don't think this has a high priority, but it would be a nice feature anyways.

PMJMendes commented 7 years ago

Hey, :)

From: Springrbua [mailto:notifications@github.com]

this should be solved for typescript in general, not only for angular (in my opinion).

I don't think this has a high priority, but it would be a nice feature anyways.

Agree on all counts.

Cheers, J.