예제 #1
0
        public void Create_and_initialize_operation()
        {
            var sqlOperation = new SqlOperation("MySql");

            Assert.Equal("MySql", sqlOperation.Sql);
            Assert.True(sqlOperation.IsDestructiveChange);
        }
예제 #2
0
        public void Dispatches_visitor()
        {
            var sqlOperation = new SqlOperation("MySql");
            var mockVisitor = new Mock<MigrationOperationSqlGenerator>(new RelationalTypeMapper());
            var builder = new Mock<IndentedStringBuilder>();
            sqlOperation.GenerateSql(mockVisitor.Object, builder.Object);

            mockVisitor.Verify(g => g.Generate(sqlOperation, builder.Object), Times.Once());
        }
 public virtual void Visit([NotNull] SqlOperation sqlOperation, [NotNull] TContext context)
 {
     VisitDefault(sqlOperation, context);
 }