예제 #1
0
            public override void establish_context()
            {
                property = ReflectionHelper.GetAccessor((Expression<Func<ListEntity, IEnumerable<string>>>)(x => x.GetterAndSetter));
                target = new ListEntity();

                sut = new ReferenceBag<ListEntity, string>(property, new[] { "foo", "bar", "baz" });
            }
예제 #2
0
        public override void establish_context()
        {
            property = ReflectionHelper.GetAccessor (GetPropertyExpression ());
            target = new ListEntity();

            listItems = new[] {"foo", "bar", "baz"};
            sut = new List<ListEntity, string>(property, listItems);
        }
예제 #3
0
        public override void establish_context()
        {
            property = ReflectionHelper.GetAccessor((Expression<Func<ListEntity, IEnumerable>>)(x => x.List));
            target = new ListEntity();

            sut = new List<ListEntity, string>(property, new[] {"foo", "bar", "baz"});

            target.List = new List<string> {"foo", "bar", "baz"};
        }
예제 #4
0
        public override void establish_context()
        {
            property = ReflectionHelper.GetProperty((Expression<Func<ListEntity, IEnumerable<string>>>)(x => x.TypedSet));
            target = new ListEntity();

            sut = new List<ListEntity, string>(property, new[] {"foo", "bar", "baz"});

            target.TypedSet.AddAll(new[] {"foo", "bar", "baz"});
        }