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

Exclude Views (AspNetCoreGeneratedDocument) folder from coverage coverlet #1375

Closed
yacine-karim opened this issue Aug 26, 2022 Discussed in #1374 · 5 comments
Closed

Exclude Views (AspNetCoreGeneratedDocument) folder from coverage coverlet #1375

yacine-karim opened this issue Aug 26, 2022 Discussed in #1374 · 5 comments
Labels
documentation duplicate This issue or pull request already exists stale

Comments

@yacine-karim
Copy link

Discussed in #1374

Originally posted by dev0karim0yassine August 26, 2022
Hello everyone

I have this class AspNetCoreGeneratedDocument.Views_Users__AddOrUpdateUser appearring in the code coverage result

Assembly: Solution.Web
Class: AspNetCoreGeneratedDocument.Views_Users__AddOrUpdateUse

When i click on the class to check it, it takes me to the _AddOrUpdateUser View in the view folder

Path: D:\a\1\s\Solution.Web\Views\Users_AddOrUpdateUser.cshtml

I want to exclude this folder using the .runsettings file:

<?xml version="1.0" encoding="utf-8" ?>
<RunSettings>
	<DataCollectionRunSettings>
		<DataCollectors>
			<DataCollector friendlyName="XPlat code coverage">
				<Configuration>
					<!-- Globbing filter -->
					<ExcludeByFile>**/Solution.Web/Views/*.cshtml</ExcludeByFile>
					<IncludeTestAssembly>false</IncludeTestAssembly>
					<DeterministicReport>false</DeterministicReport>
				</Configuration>
			</DataCollector>
		</DataCollectors>
	</DataCollectionRunSettings>
</RunSettings>
```</div>
@MarcoRossignoli MarcoRossignoli added feature-request New feature request and removed feature-request New feature request labels Sep 28, 2022
@MarcoRossignoli
Copy link
Collaborator

MarcoRossignoli commented Sep 28, 2022

Why don't filter by type name?
I don't know if the pdb will report Users_AddOrUpdateUser.cshtml as source file and maybe we cannot exclude it(but I didn't investigate).

@MarcoRossignoli MarcoRossignoli added feature-request New feature request waiting for customer Waiting for customer action labels Sep 28, 2022
@github-actions
Copy link

github-actions bot commented Sep 4, 2023

This issue is stale because it has been open for 3 months with no activity.

@github-actions github-actions bot added the stale label Sep 4, 2023
@BodanGjozinski
Copy link

Hey everyone,

So this issue is the same as this one:
Same Issue

And i also answered it on Stack overflow i think for the same person a year and a half late 😄
Stack overflow question

@github-actions github-actions bot removed the stale label Apr 7, 2024
@Bertk Bertk added duplicate This issue or pull request already exists documentation and removed feature-request New feature request waiting for customer Waiting for customer action labels Apr 7, 2024
Copy link

github-actions bot commented Jul 7, 2024

This issue is stale because it has been open for 3 months with no activity.

@github-actions github-actions bot added the stale label Jul 7, 2024
@Bertk
Copy link
Collaborator

Bertk commented Jul 21, 2024

Duplikate issue is closed. Please see also Stack overflow information.

Hey everyone,

So this issue is the same as this one: Same Issue

And i also answered it on Stack overflow i think for the same person a year and a half late 😄 Stack overflow question

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation duplicate This issue or pull request already exists stale
Projects
None yet
Development

No branches or pull requests

4 participants