docs icon indicating copy to clipboard operation
docs copied to clipboard

Add usage page about filters

Open fflaten opened this issue 3 years ago • 1 comments

Consider rewriting Tags-page to be about filters in general. Should explain behavior when multiple filters are used like exclude/include/explicit priority. The latter is only indirectly mentioned on other pages, including deprecated v4-parameters in Invoke-Pester command ref.

I have a PesterConfiguration with two filter options set - $configuration.Filter.Tag and $configuration.Filter.FullName.

I expected, that the both filters will apply to the subset of tests and it'll narrow down the search so only specified tests that has the selected tag will be run. Pester works in a different manner. It creates a union of two filters so all the tests specified in $configuration.Filter.FullName will be launched as well as all the tests having $configuration.Filter.Tag tags.

If that's the strategy we expect from Pester, maybe we could mention this behavior it in the New-PesterConfiguration Filter documentation.

Originally posted by @tempora-mutantur in https://github.com/pester/Pester/issues/2278#issuecomment-1365287272

fflaten avatar Dec 26 '22 23:12 fflaten

Resource: https://github.com/pester/Pester/issues/1442

fflaten avatar Dec 26 '22 23:12 fflaten