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

Notification

Icon
Error

(v1.37b) yellow marker for slow tests issue
liviuu
#1 Posted : Wednesday, February 8, 2012 12:10:45 AM(UTC)
Rank: Member

Groups: Registered
Joined: 9/6/2011(UTC)
Posts: 11
Location: liviuu

Was thanked: 1 time(s) in 1 post(s)

The statements raising exceptions, inside tests that fail, are counted for the average duration.
The time spend when raising exceptions should be ignored.

Remco
#2 Posted : Wednesday, February 8, 2012 12:51:27 AM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 6,976

Thanks: 931 times
Was thanked: 1257 time(s) in 1170 post(s)
Thanks for posting. Could you share your thoughts about how such a change would be useful to you? Sometimes exceptions are actually raised as normal behaviour in programs and it would be useful to be able to establish the performance penalty for this.
liviuu
#3 Posted : Wednesday, February 8, 2012 3:54:26 PM(UTC)
Rank: Member

Groups: Registered
Joined: 9/6/2011(UTC)
Posts: 11
Location: liviuu

Was thanked: 1 time(s) in 1 post(s)
Hi,

Maybe i was not very detailed and clear in my explanation (english is second language).

I have test method Test1.

The test failed in NCrunch at statement Stmt1.

I think it is not relevant for the average time to count the time spent in the failing test. My goal is to have only working tests.
If i want to test the exception raised i would guard them using exception asserts:

Assert.ThrowException<EXX>( code xxx ). the test would not fail, and the average running time calculated for passing tests will be relevant also for the scenarios where the code throws.
Remco
#4 Posted : Wednesday, February 8, 2012 9:27:52 PM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 6,976

Thanks: 931 times
Was thanked: 1257 time(s) in 1170 post(s)
Am I correct in my understanding that you want to disregard any performance metrics that are derived from a failed test? I guess the only way I could see this working is if NCrunch were to separate the performance information from the code coverage ... this could be quite confusing if you were hovering the cursor over a black marker and NCrunch was telling you that the marker had an execution time, but no tests that covered it..
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.035 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download