Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: Run on demand #400

Closed
mdima opened this issue Mar 8, 2024 · 8 comments
Closed

Request: Run on demand #400

mdima opened this issue Mar 8, 2024 · 8 comments

Comments

@mdima
Copy link

mdima commented Mar 8, 2024

Hello,
I just discovered this extension and I really love it.
Just: I would like to run the Coverage Test only when I decide to run a global test, not when I run a single Unit Test.

Is there any way to run it "on demand"? I did not find anything in the documentation...

Thanks,
Michele

@tonyhallett
Copy link
Collaborator

I assume you do not like it when running a single test will run all tests. By setting the option RunMsCodeCoverage to true only what you select in test explorer gets tested and receives coverage.

@mdima
Copy link
Author

mdima commented Mar 8, 2024

I assume you do not like it when running a single test will run all tests. By setting the option RunMsCodeCoverage to true only what you select in test explorer gets tested and receives coverage.

Hello, thank you for your answer.
Well... this option makes the things easier, but still I get marked as "not tested" all the rest of the code that is not involved in the test I just run.

Probably a simple button "calculate coverage" to click on demand would be easy to manage.
I mean, this utility is super-useful, just produce a lot of elaboration (and results) during the normal developing.

Thanks,
Michele

@tonyhallett
Copy link
Collaborator

Probably a simple button "calculate coverage" to click on demand would be easy to manage.

No. Coverage works by reacting to the test explorer.

As it stands disabling clears all coverage too so that is not an option either.

Afraid you will have to wait until this feature ( actual specific desired behaviour not provided in either issue ) is implemented.
#325
#316

If you could explain in either of those issue how you expect FCC to behave given the information available which is solely the cobertura file before and after then that would be great.

@tonyhallett
Copy link
Collaborator

If you could explain in either of those issue how you expect FCC to behave given the information available which is solely the cobertura file before and after then that would be great.

and the code files in the project.

@mdima
Copy link
Author

mdima commented Mar 18, 2024

Hello,
yes, I think this issue is related to the #316 issue.
I am trying FCC in a quite big project where we have more than 270 tests, and running them takes about 10 minutes (there are call to some external APIs that have a request quota).
So what I see is that I run the tests, after that FCC starts to process all the tests again (instead of using the previous run as source for its data), and that doubles the time we have to wait. Also, another way could be running directly FCC...

Anyway, if you don't have VS Enterprise this is a very useful tool...

Thanks,
Michele

@tonyhallett
Copy link
Collaborator

So what I see is that I run the tests, after that FCC starts to process all the tests again (instead of using the previous run as source for its data), and that doubles the time we have to wait

I believe that you are saying that FCC runs all the tests again. This does not occur if you set the RunMsCodeCoverage to Yes.

@mdima
Copy link
Author

mdima commented Mar 18, 2024

Yes, you are right.
I tried RunMsCodeCoverage to Yes, but with this setting the only analysis I receive is on the TestMethod I run, nothing else.
The method I test during the unit test are not analized (no entry in the FCC window and no line coverage in the tested method).

Another thing which is not easy to understand is when the extension is running some test or not. Maybe a kind of "semaphore" in the FCC window would be useful.

Thanks,
Michele

@tonyhallett
Copy link
Collaborator

I tried RunMsCodeCoverage to Yes, but with this setting the only analysis I receive is on the TestMethod I run, nothing else.
The method I test during the unit test are not analized (no entry in the FCC window and no line coverage in the tested method).

The method you test does get analysed.

Another thing which is not easy to understand is when the extension is running some test or not.

image

There is an asterisk semaphore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants