示例#1
0
        public void InstantiateNonMigrationClass_Skip()
        {
            var sut = new MigrationFactory();

            var result = sut.Create(new List <Type> {
                typeof(string)
            })
                         .ToList();

            Assert.Empty(result);
        }
示例#2
0
        public void InstantiateMigration()
        {
            var sut = new MigrationFactory();

            var result = sut.Create(new List <Type> {
                typeof(B1Migration)
            })
                         .ToList();

            Assert.IsType <B1Migration>(result.Single());
        }
        public void UseActivatorToCreateFact()
        {
            // Arrange
            var factory = new MigrationFactory();

            // Act
            var migration = factory.Create(typeof(MigrationStub));

            // Assert
            migration.Should().NotBe(null);
            migration.Should().BeOfType <MigrationStub>();
        }