Example #1
0
def test_forgiving_add_column():
    """Test that add column will continue if column exists."""
    engine = create_engine('sqlite://', poolclass=StaticPool)
    engine.execute('CREATE TABLE hello (id int)')
    migration._add_columns(engine, 'hello', [
        'context_id CHARACTER(36)',
    ])
    migration._add_columns(engine, 'hello', [
        'context_id CHARACTER(36)',
    ])
def test_forgiving_add_column():
    """Test that add column will continue if column exists."""
    engine = create_engine(
        'sqlite://',
        poolclass=StaticPool
    )
    engine.execute('CREATE TABLE hello (id int)')
    migration._add_columns(engine, 'hello', [
        'context_id CHARACTER(36)',
    ])
    migration._add_columns(engine, 'hello', [
        'context_id CHARACTER(36)',
    ])
Example #3
0
def test_forgiving_add_column():
    """Test that add column will continue if column exists."""
    engine = create_engine("sqlite://", poolclass=StaticPool)
    engine.execute("CREATE TABLE hello (id int)")
    migration._add_columns(engine, "hello", ["context_id CHARACTER(36)"])
    migration._add_columns(engine, "hello", ["context_id CHARACTER(36)"])