@skipUnlessDBFeature('requires_rollback_on_dirty_transaction')
    def test_bad_sql(self):
        execute_bad_sql = transaction.commit_on_success(self.execute_bad_sql)
        self.assertRaises(IntegrityError, execute_bad_sql)
        transaction.rollback()
Register a function or Check class as a policy check.
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.5/tests/modeltests/transactions/tests.py/TransactionRollbackTests.test_bad_sql--crossover with--dataset/ETHPy150Open CiscoSystems/avos/openstack_dashboard/openstack/common/policy.py/register