public void Create_and_initialize_operation()
        {
            var sequence = new Sequence("dbo.MySequence");
            var createSequenceOperation = new CreateSequenceOperation(sequence);

            Assert.Same(sequence, createSequenceOperation.Sequence);
            Assert.False(createSequenceOperation.IsDestructiveChange);
        }
        public void Dispatches_visitor()
        {
            var createSequenceOperation = new CreateSequenceOperation(new Sequence("dbo.MySequence"));
            var mockVisitor = new Mock<MigrationOperationSqlGenerator>(new RelationalTypeMapper());
            var builder = new Mock<IndentedStringBuilder>();
            createSequenceOperation.GenerateSql(mockVisitor.Object, builder.Object);

            mockVisitor.Verify(g => g.Generate(createSequenceOperation, builder.Object), Times.Once());
        }
 public virtual void Visit([NotNull] CreateSequenceOperation createSequenceOperation, [NotNull] TContext context)
 {
     VisitDefault(createSequenceOperation, context);
 }
        public void Generate_with_create_sequence_not_supported()
        {
            var operation = new CreateSequenceOperation(new Sequence("EpisodeSequence"));

            Assert.Throws<NotSupportedException>(() => Generate(operation));
        }
 public override void Generate(
     CreateSequenceOperation createSequenceOperation,
     IndentedStringBuilder stringBuilder)
 {
     throw new NotSupportedException();
 }