def test_drop_views(self):
        views = ('view1', 'view2')
        self._setup_exists_expects(views, 'VIEWS')

        for view in views:
            self.manager.execute.expect_call('DROP VIEW `%s`' % view)

        db_utils.drop_views(self.manager, views)
        self.god.check_playback()
    def test_drop_views(self):
        views = ("view1", "view2")
        self._setup_exists_expects(views, "VIEWS")

        for view in views:
            self.manager.execute.expect_call("DROP VIEW `%s`" % view)

        db_utils.drop_views(self.manager, views)
        self.god.check_playback()
def migrate_down(manager):
    db_utils.drop_views(manager, VIEWS_TO_DROP_DOWN)
    db_utils.rename(manager, RENAMES_DOWN)
    manager.execute_script(RECREATE_VIEWS_DOWN)
def migrate_down(manager):
    db_utils.drop_views(manager, VIEWS_TO_DROP_DOWN)
    db_utils.rename(manager, RENAMES_DOWN)
    manager.execute_script(RECREATE_VIEWS_DOWN)