Exemplo n.º 1
0
        public void GetEntities_No_Matches()
        {
            VCardEntityList<VCardSimpleValue> list = new VCardEntityList<VCardSimpleValue>()
            {
                new VCardSimpleValue("one", "1"),
                new VCardSimpleValue("two", "2"),
            };

            var result = list.GetEntities("three");

            CollectionAssert.IsEmpty(result);
        }
Exemplo n.º 2
0
        public void GetEntities_Two_Of_Three_Matches()
        {
            VCardEntityList<VCardSimpleValue> list = new VCardEntityList<VCardSimpleValue>()
            {
                new VCardSimpleValue("one", "1"),
                new VCardSimpleValue("two", "2A"),
                new VCardSimpleValue("two", "2B"),
            };

            VCardSimpleValue[] result = list.GetEntities("two").ToArray();

            Assert.That(result.GetLength(0), Is.EqualTo(2));
            CollectionAssert.AllItemsAreUnique(result);
        }