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

Notification

Icon
Error

ncrunch 2.22 pinning tests automagically?
StephenFriend
#1 Posted : Tuesday, May 17, 2016 10:39:08 AM(UTC)
Rank: Newbie

Groups: Registered
Joined: 5/17/2016(UTC)
Posts: 4
Location: United Kingdom

Thanks: 2 times
Was thanked: 1 time(s) in 1 post(s)
Hi there,

I've just installed 2.22 (VS2015 update 1) and am seeing some unexpected behaviour. I have the engine mode set to 'Run pinned tests automatically, others manually', when I switched branches in git, which caused some projects to reload, nCrunch started running some tests, seemingly because they were getting pinned into the test runner window.

After processing queue had finished and nCrunch was idle, I:
1) clicked the unpin all tests button (while in branch y) (so that the test runner window was empty)
2) switched back to the previous branch (branch x)
3) reloaded the projects that had changed, as prompted by Visual Studio (and again saw tests get pinned to the runner window)
5) waited for nCrunch to finish all of its processing
4) clicked the unpin all tests button (so that the test runner window was empty)
5) switched back to the branch I want to work in (branch y)
6) reloaded the projects that had changed, as prompted by Visual Studio
7) waited for nCrunch to do its thing and watched as tests became magically pinned to the window

Is this expected behaviour? Given that I like to work using the pinned tests mode, having tests that I'm not interested in get run is an overhead that is quite annoying.

Thanks,
Steve
Remco
#2 Posted : Tuesday, May 17, 2016 10:55:05 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 964 times
Was thanked: 1296 time(s) in 1202 post(s)
Hi Steve -

This is expected behaviour. It's controlled by a feature you can turn on and off under the 'Customise engine modes' option. When in the standard 'Run pinned tests automatically' mode, NCrunch will automatically pin newly discovered tests to the tests window. The idea behind this is that newly discovered tests are usually deliberately introduced (i.e. you're writing new tests in a fixture and you're interested in them).

It doesn't work well for branch switching, because this tends to create new tests between sessions. I'd suggest just turning it off under your engine mode settings.
1 user thanked Remco for this useful post.
StephenFriend on 5/17/2016(UTC)
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.027 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download