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

Notification

Icon
Error

2 Pages12>
doe not 'Go to selected test'
krutzki
#1 Posted : Tuesday, February 4, 2014 9:48:26 PM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
really annoying...right click on the test in the output window and select 'Go to Selected test' in VS 2012 and it simply does not do anything or sometimes it just goes to the completely unrelated and wrong test.

I end up doing a global search for the name of the test

using Moq, also have resharper installed


besides that it works fine and is a useful product but can anyone help with this..?

thanks
Remco
#2 Posted : Tuesday, February 4, 2014 11:24:19 PM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Hi, thanks for sharing this issue.

The issue is caused by NCrunch being unable to resolve the method or property representing the test. Do you find this happens consistently for certain tests? Or is it an intermittent problem?

If you can narrow it down to a single test that causes it consistently, is there any chance you can post the declaration of the test? (content shouldn't be important unless it's dynamically generated using TestCaseSource).

If you can submit a bug report after it's happened to you, this may also help in case the issue is being caused by something going wrong inside the engine.


Cheers,

Remco
krutzki
#3 Posted : Wednesday, February 5, 2014 2:51:52 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
Hi,
this happens all the time. It is not an intermittent problem. The tests are not dynamically generated.

I have submitted a bug report just now after I went into VS and made it happen again.

I double clicked on a test in the NCrunch output window and it navigated to a completely different test, although the test was in the same file. I went to a different test in the output window and double clicked and nothing happened.

Should I be disabling VS test or something?

thanks
Remco
#4 Posted : Wednesday, February 5, 2014 3:27:40 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Hi, thanks for submitting the bug report.

I noticed that you're still running on v1.46, which is getting quite old now. There's been many fixes in this area since 1.46 was released, so I strongly suspect you may be dealing with a resolved bug.

Would you like to try one of the later builds to see if this solves the issue? The most recent is 2.4, which just hit RTM last week.
krutzki
#5 Posted : Thursday, February 6, 2014 3:08:10 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
thanks. Will update. suppose I should have tried that first :)
krutzki
#6 Posted : Wednesday, February 12, 2014 2:49:55 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
updated to 1.48.0.5. Seems I could only register as a trial for later versions..but problem still there. Have submitted a bug report again

My work bought this for me..am I able to download a more recent version or..?
Remco
#7 Posted : Wednesday, February 12, 2014 2:59:47 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
V2.4 is a free download, and it comes with a 30 day evaluation license. I'd recommend giving it a try, as it is much more stable than any of the V1 releases and may include a fix for this problem.

I'd also recommend trying to use your existing V1 license with V2.4. If the license was bought after 2013-01-31, it should work with V2.4.

Thanks for submitting the bug report. Sadly the report didn't include anything that points directly to the problem, but it does help with the process of elimination. Let me know how you get on with V2.4, and if the problem persists, I'll try to help you from there.
krutzki
#9 Posted : Wednesday, February 12, 2014 10:35:12 PM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
downloaded 2.4...IDE crashing...uninstall ncrunch
Remco
#10 Posted : Wednesday, February 12, 2014 10:52:40 PM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Can you share any more details about the crash? Is there a specific time at which it happens? How does the crash behave? Does it throw up a big exception dialog asking if you want to debug? Do you have any other VS extensions installed or are you running on a system with limited memory?
krutzki
#11 Posted : Thursday, February 13, 2014 12:50:01 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
installed update 4 to VS2012. 3.5gb download...reinstalled Ncrunch 2.4 and now it works. Original issue seems to be resolved as well

8gb memory, PowerTools, NuGet and AttachTo are the other extension I have installed

My original issue was 'inconvenient' only. Had I know I need to install new framework or need to update VS with a > 3gb download I probably would not have installed it or atleast planned the download better. As it turned out I blew most of the morning waiting for the download. Maybe if that was made clearer on the downloads page that I needed 4.5.1 or VS2012 Update 4 that would be helpful

Installing 2.4 without these installed first is not pretty

Thanks for your quick responses and help

EDIT: I looked thru the download section and as far as I can see it does not mention .NET 4.5.1 anywhere and the 'list of supported tools and frameworks.' seems to suggest the no updates are required.

Anyway, I am glad I have it installed again as it is a very useful tool
Remco
#12 Posted : Thursday, February 13, 2014 1:50:33 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Great to hear that you got it working. I'm sorry to hear that it put you through the blender without warning.

NCrunch shouldn't normally require v4.5.1 in order to work correctly, but I am aware that there is an unintended dependency on executing code in v4.5 requiring v4.5.1, because of the task runner involved. This wasn't deliberate and will be fixed in the next minor release.

I wasn't aware of any dependency on VS2012 Update 4. As far as I know, NCrunch should work correctly without this update and was available in VS2012 well before the update was released. Most likely this was a related component or package that was failing, perhaps in response to the "devenv.exe /setup" action that the NCrunch installer performs to load itself into VS. VS stability can be a bit of a nightmare as it is a process shared by many different packages usually from many different vendors. All it takes is one package to do something a bit strange, and some very crazy things can happen. I guess we'll never know why your system was crashing, but I'm still glad the update fixed it.
krutzki
#13 Posted : Thursday, February 13, 2014 2:35:56 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
FYI, I have Resharper installed as well and use the 'Unit Test Sessions' window often to run/debug tests. This has stopped working and now does not go beyond 'Pending' when attempting to run. This however may not have anything to do with NCrunch - could be todo with Update to VS but thought you might like to know

Remco
#14 Posted : Thursday, February 13, 2014 3:08:16 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Thanks for letting me know. I'm not aware of any compatibility issue here with NCrunch. NCrunch gets tested extensively in IDEs with ReSharper loaded and there is no integration between the products. You may be able to confirm by uninstalling NCrunch to see if this makes any difference.
1 user thanked Remco for this useful post.
krutzki on 2/13/2014(UTC)
krutzki
#15 Posted : Thursday, February 13, 2014 3:22:04 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
updated Resharper to 7.1.3 from 7.1.2 and now the unit test works. Nothing to do with NCrunch.
krutzki
#16 Posted : Friday, February 14, 2014 12:49:44 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
UPDATE: now it is doing it again. When dbl clicking on test in 'NCrunch Tests' window it goes to a different test method in the same test class.

Is there something wrong with the indexing? I am assuming it indexes the test files/methods and attempt to go to a location where the index points (made assumption on how it works).

If this is correct can I update/refresh the index?

Remco
#17 Posted : Friday, February 14, 2014 3:20:06 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
The index is stored inside the .cache file under the _NCrunch_Solution directory.

You can try deleting this file to see if it makes any difference - although I would really like to know how it's getting messed up.

Can you share any details on how these tests are structured? Are they making use of inheritance or interesting arrangements?

I can probably reproduce+fix this problem very quickly if you're able to supply a code sample that demonstrates the problem. This could be as simple as just taking your test project, removing its references and all the code except for the test declarations causing problems, and packaging this with the .cache information intact. You're welcome to submit any code through the contact form.

Thanks!

Remco
krutzki
#18 Posted : Tuesday, March 18, 2014 9:32:27 PM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
hi,

sorry to reactivate this one. I have a new machine. Win7/VS2012, ncrunch 2.5.0.12 - same issue.

Still does not go to the test double click or right click and use menu. I have to manually load a seach box and type in the name of the test and let VS find the test. This really is 'annoying'....I really like what else ncrunch does but this is really fundamental to navigating to the test and is really slowing me down...is there anything else I could try?
Remco
#19 Posted : Tuesday, March 18, 2014 9:50:47 PM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Hi,

Sorry but I'm still not sure why this issue is appearing for you. Is there any code you can share with me including a .cache file with the problem? I'm afraid it's hard to analyse the issue without being able to observe it in action.
Remco
#21 Posted : Wednesday, March 19, 2014 1:34:58 AM(UTC)
Rank: NCrunch Developer

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

Thanks: 957 times
Was thanked: 1286 time(s) in 1193 post(s)
Hi,

Thanks for sending through the sample code. I was able to reproduce the problem and can confirm that it is related to the ExcludeFromCodeCoverage attribute, which seemed to be causing problems for NCrunch when applied at fixture level.

I've prepared a build that includes a fix for this problem. You're welcome to try it if you like:

http://downloads.ncrunch.net/NCrunch_GridNodeServer_2.6.0.7.msi
http://downloads.ncrunch.net/NCrunch_GridNodeServer_2.6.0.7.zip
http://downloads.ncrunch.net/NCrunch_VS2008_2.6.0.7.msi
http://downloads.ncrunch.net/NCrunch_VS2010_2.6.0.7.msi
http://downloads.ncrunch.net/NCrunch_VS2010_2.6.0.7.zip
http://downloads.ncrunch.net/NCrunch_VS2012_2.6.0.7.msi
http://downloads.ncrunch.net/NCrunch_VS2012_2.6.0.7.zip
http://downloads.ncrunch.net/NCrunch_VS2013_2.6.0.7.msi
http://downloads.ncrunch.net/NCrunch_VS2013_2.6.0.7.zip


Alternatively, you can work around this problem by removing the ExcludeFromCodeCoverage attribute from your test fixtures. Applying this attribute at method (test) level will not cause the problem. You could also look into using code coverage suppression comments as an alternative.
1 user thanked Remco for this useful post.
krutzki on 3/19/2014(UTC)
krutzki
#22 Posted : Wednesday, March 19, 2014 1:51:26 AM(UTC)
Rank: Member

Groups: Registered
Joined: 2/4/2014(UTC)
Posts: 14
Location: Australia

Thanks: 2 times
can confirm that it appears to be working - downloaded latest build and installed.

can you pls confirm that you got my message and that it was actioned

really appreciate your responsiveness and fixes. Thanks :)

Users browsing this topic
Guest (2)
2 Pages12>
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.267 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download