예제 #1
0
        public void NotMatchWithStringProperty()
        {
            var mi = typeof(Entity).GetProperty("Simple");
            var p  = new ArrayCollectionPattern();

            p.Match(mi).Should().Be.False();
        }
예제 #2
0
        public void NotMatchWithCollectionField()
        {
            var mi = typeof(Entity).GetField("others", BindingFlags.NonPublic | BindingFlags.Instance);
            var p  = new ArrayCollectionPattern();

            p.Match(mi).Should().Be.False();
        }
예제 #3
0
        public void MatchWithCollectionPropertyAndArrayField()
        {
            var mi = typeof(Entity).GetProperty("Emails");
            var p  = new ArrayCollectionPattern();

            p.Match(mi).Should().Be.True();
        }
예제 #4
0
        public void MatchWithArrayField()
        {
            var mi = typeof(Entity).GetField("emails", BindingFlags.NonPublic | BindingFlags.Instance);
            var p  = new ArrayCollectionPattern();

            p.Match(mi).Should().Be.True();
        }
예제 #5
0
        public void MatchWithArrayProperty()
        {
            var mi = typeof(Entity).GetProperty("NickNames");
            var p  = new ArrayCollectionPattern();

            p.Match(mi).Should().Be.True();
        }
예제 #6
0
        public void NotMatchWithByteArrayProperty()
        {
            var mi = typeof(Entity).GetProperty("Photo");
            var p  = new ArrayCollectionPattern();

            p.Match(mi).Should().Be.False();
        }