+1 for [ExpectedException]  (and ideally another attribute to indicate 
which JIRA it corresponds to).

This way once a bug is fixed (deliberately, or not), the test will 
highlight it.  If the tests are marked as [Explicit], then they could 
potentially be left to stagnate once a bug is fixed.



On Wednesday, 11 December 2013 07:03:41 UTC, Kamil Kliczbor wrote:
>
> Hi Alex,
> from my personal perspective I would prefer to mark the test with the 
> Explicit and Category as well. The name of the category should be in const.
> Like this 
>
> [Test, Explicit, Category(BugCategory.Failing)]
>
> where 
>
>  public class BugCategory
>     {
>         public const string Failing = "Failing";
>     }
>
> Why this approach? Well, during the development I want to stay focused on 
> the tests that are passing and I can see what I broke. But while having 
> some tests red and some tests green I would be forced to additionally track 
> the tests and compare the results before and after applying the code to the 
> project.
>
> regards,
> Kamil
>
>
> W dniu środa, 11 grudnia 2013 07:38:01 UTC+1 użytkownik RichB napisał:
>>
>> How about:
>>
>> [Category("Buggy")]
>>
>>  http://www.nunit.org/index.php?p=category&r=2.2
>>
>>
>> Richard
>>
>> On 11 Dec 2013, at 01:48, "Alexander I. Zaytsev" <[email protected]> 
>> wrote:
>>
>> Hi guys,
>>
>> We have a lot of test cases which our users contributed, but the tests 
>> are still failing. 
>> I want these tests to be in the repository, but I'm not sure how to state 
>> them that we are expecting them to fail because they are `known bugs`.
>>
>> There are several possible ways:
>> - Mark tests with [ExpectedException] - execute test and expect 
>> exception. This is the closest one to what I want to achieve.
>> - Mark tests with [Explicit] - execute tests only when asked
>> - Mark tests with [Ignore] - do not execute tests at all.
>>
>> Any other ways to do this? 
>>
>> What do you prefer?
>>
>> Best Regards, 
>> Alexander
>>  
>> -- 
>>  
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "nhibernate-development" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"nhibernate-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to