def test_drop_column_not_in_version(self):
another_column = ForeignKeyField(
Menu, related_name='food', null=True, to_field=Menu.id)
migrate(migrator.add_column('food', 'another_column', another_column))
self.assertTableDoesNotHaveColumn('foodversion', 'another_column')
migrate(migrator.drop_column('food', 'another_column'))
self.assertTableDoesNotHaveColumn('food', 'another_column')
评论列表
文章目录