Hi Peter,

It's a bug in value equality of Assert.In.

I'll file this in JIRA.


On 7/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
> Hi,
>
> Problem with Assert.In(object, IEnumerable) ?
>
> The following demonstrates
>
>     [TestFixture]
>     public class Tests
>     {
>         enum MyEnum
>         {
>             EnumOne,
>             EnumTwo,
>             EnumThree
>         }
>
>         [Test]
>         public static void test1()
>         {
>             List<MyEnum> myEnumList = new List<MyEnum>();
>             myEnumList.Add(MyEnum.EnumOne );
>             myEnumList.Add(MyEnum.EnumThree);
>
>             Assert.In(MyEnum.EnumOne, myEnumList); //pass
>             Assert.In(MyEnum.EnumOne,
> (IEnumerable<MyEnum>)myEnumList); //fail
>
>              Assert.NotIn(MyEnum.EnumTwo, myEnumList); //pass
>             Assert.NotIn(MyEnum.EnumTwo,
> (IEnumerable<MyEnum>)myEnumList); //pass
>         }
>     }
>
> I have a class property that returns IEnumerable<T>, should is work
> with Assert.In and NotIn?
>
> Thanks
>
> Peter
>
>
> >
>


-- 
----------------------
joeycalisay
http://devpinoy.org/blogs/joeycalisay/

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"MbUnit.User" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/MbUnitUser?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to