Include Filter combinations

Include Filter combinations

Suppose I have a huge project with many assemblies. I'd like to include everything from the assemblies I own, and include one namespace from a shared web project:

Assembly (MyProject1|MyProject2) true True Namespace MyProject3.Web.UI.Admin.* true True

My problem is that code will be excluded unless both include filters are matched. I would expect code to be included if any one filter matches.

Is this a bug or a design decision? Can we have a switch that specifies which mode the report should operate in? Include filters are unusable until we have a fix for this.


RE: Include Filter combinations

We process include files and then exclude filters. I am not a regex wizard but as long as the first regex matches a string correctly, it would be included. I think we also perform a case insensitive search.

I think the bug in 3.0.18 may be it is attempting to perform an exact match including the signature.

Can you see if (MyProject1.|MyProject2.) fixes your issue.

I can also send you a pre release version.

Can you email your coverage file and your script to support and I can look at it for you?

Thanks

Joe


RE: Include Filter combinations

I think the problem is more specifically in how different filter types are combined. In my example, I was trying to match either anything in an assembly named x, or anything in namespace y.

If I switch the filters to both match by namespace, it works as expected.

I can sort of see why you would want both an assembly and namespace filter to match in order to include a piece of code, but it wasn't immediately intuitive.

Our solution is to only match on namespaces.

Thanks

Chris


RE: Include Filter combinations

Chris,

We are still looking at this issue but my hunch is since you told us to only include a namespace in that second assembly but not the assembly itself, the namespace is not included.

The objects are tree based, so a child can't be included unless it's parent is.

We are looking at changing this behavior in a future release.

With your first example, try including the assembly of that item that you wish to just include the namespace.

Joe