Example #1
0
        public void CanGetKeyFromEntity()
        {
            var subject = new KeyBinder <TestEntity, string>(entity => entity.Key, (e, k) => e.Key = k);

            var key = subject.Get(new TestEntity {
                Key = "Key1"
            });

            Assert.Equal("Key1", key);
        }