public void PopulateThrowsExceptionWithNullTypeTest()
        {
            var executeStrategy = new DummyExecuteStrategy();

            var target = new DefaultTypeCreator();

            Action action = () => target.Populate(null, executeStrategy);

            action.ShouldThrow<ArgumentNullException>();
        }
        public void PopulateReturnsProvidedInstanceTest()
        {
            var executeStrategy = new DummyExecuteStrategy();
            var expected = new SlimModel();

            var target = new DefaultTypeCreator();

            var actual = target.Populate(expected, executeStrategy);

            actual.Should().BeSameAs(expected);
        }
        public void PopulateThrowsExceptionWhenPopulateVerificationFailsTest()
        {
            var executeStrategy = new DummyExecuteStrategy();

            var target = new TypeCreatorWrapper();

            Action action = () => target.Populate(false, executeStrategy);

            action.ShouldThrow<NotSupportedException>();
        }
        public void PopulateDoesNotThrowsExceptionWhenPopulateVerificationPassesTest()
        {
            var executeStrategy = new DummyExecuteStrategy();
            var value = new List<string>();

            var target = new TypeCreatorWrapper();

            Action action = () => target.Populate(value, executeStrategy);

            action.ShouldNotThrow();
        }