Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Rider: Elapsing Ignored Test in NCrunch Test Windows on unignoring
Der-Albert.com
#1 Posted : Wednesday, July 9, 2025 1:58:56 PM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 5/17/2011(UTC)
Posts: 217

Thanks: 12 times
Was thanked: 56 time(s) in 52 post(s)
I have a Project, with several Test Projects.

Two of them are (sorted Descending after Name)

- SystemTests
- IntegrationsTests

Both are collapsed and ignored (because the System Tests are not NCrunch compatible), but some Integration Tests are longer Running. So i normally Integration Tests.
There are more Tests Projects, but these are not ignored. Also I filter only to show ignored Tests (to unignore Tests).

Bug A)
Not able to Unignore alle IntegrationTests on the Project Level, I have to unignore on the Namespace or lower level (Grouping is Project, Namespace, Fixture, Tests)

Bug B)
In the above Setting i would like to unignore some Integration Tests, so i elapsed them until I find my tests, i unignore them.
But then all System Tests are elapsed and i loose totally track where i was in the tests


Remco
#2 Posted : Wednesday, July 9, 2025 10:55:33 PM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,324

Thanks: 991 times
Was thanked: 1331 time(s) in 1234 post(s)
Hi, thanks for sharing this issue.

The Tests Window doesn't work very well for the ignore/unignore options when set to organise tests by category. The reason for this is because of the way ignored tests work internally in the engine.

When you ignore a test, the engine creates and stores a configuration setting that includes a selector targeting the test, depending on how you've chosen to ignore it (i.e. by fixture, project, test, etc). It's not a state flag on the test itself, but rather a wildcard system that targets all tests according to specific criteria. You can find these in your NCrunch config files (they are stored in the XML).

It's done this way because ignore settings need to go beyond the lifespan of individual tests. For example, if you ignore a fixture, it's reasonable that any new tests discovered under the fixture would be automatically ignored.

This structure falls down when it's used to specify tests being shown across multiple dimensions. When the Tests Window is set to group tests by category, for the selectors to make sense, we would need to have a category-based ignored test selector, and any selectors used to target fixtures underneath the category would likewise need to have a context specific to the category. If you were to specify an ignore selector on the category, then switched your Tests Window back to a different grouping, suddenly everything gets very confusing, because the tests being ignored are chosen by selectors working across multiple dimensions. So immediately it's not clear why a test is ignored without actually going into the config files yourself and reading the XML. The UI masks all of this complexity.

So instead the simplest, least confusing option is to only have ignore selectors work when the tests are categorised according to project structure. It is not possible to ignore by category, but it IS possible to ignore tests that are shown by category.

Generally, the ignoring of tests is something that's done more for compatibility reasons (i.e. to shut off legacy tests that don't work under NCrunch). If you find you're regularly using this feature to control test execution, then using the filters attached to the engine modes would be a much more flexible alternative.
Der-Albert.com
#3 Posted : Thursday, July 10, 2025 5:35:29 AM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 5/17/2011(UTC)
Posts: 217

Thanks: 12 times
Was thanked: 56 time(s) in 52 post(s)
That I went the route to Bug B is a result of Bug A... if I could just simply unignore the complete project, it would be enough for me. That's my normal use case (and I'm sure it worked before); no need for fine-graded control, at least for me. Everything else seems like overkill to manage which tests are run.

If I can ignore a project, I should also be able to unignore it.
Remco
#4 Posted : Friday, July 11, 2025 7:14:52 AM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,324

Thanks: 991 times
Was thanked: 1331 time(s) in 1234 post(s)
It's possible you have an ignored test selector that is causing some hierarchical problems. Check your settings files for the ignore selectors and try removing them manually (with the IDE closed). Ignoring and unignoring at project level should normally work.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

YAF | YAF © 2003-2011, Yet Another Forum.NET
This page was generated in 0.031 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download