summaryrefslogtreecommitdiff
path: root/tests/backends/sqlite
diff options
context:
space:
mode:
authorSimon Charette <charette.s@gmail.com>2018-12-21 18:06:16 -0500
committerTim Graham <timograham@gmail.com>2018-12-22 14:58:08 -0500
commit25a0781a1661e7329bc1ba9bce12dfddf7f2d433 (patch)
treed91728f96f068c4fe67d91abb3f1004f8c7f8ab0 /tests/backends/sqlite
parente5b8626c0eb223cc3d643163882c5902c40ec972 (diff)
downloaddjango-25a0781a1661e7329bc1ba9bce12dfddf7f2d433.tar.gz
Refs #29182 -- Corrected SQLite's supports_atomic_references_rename feature flag.
Diffstat (limited to 'tests/backends/sqlite')
-rw-r--r--tests/backends/sqlite/tests.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/backends/sqlite/tests.py b/tests/backends/sqlite/tests.py
index d8efdf2821..bddaf8620f 100644
--- a/tests/backends/sqlite/tests.py
+++ b/tests/backends/sqlite/tests.py
@@ -6,7 +6,9 @@ from django.db import connection, transaction
from django.db.models import Avg, StdDev, Sum, Variance
from django.db.models.fields import CharField
from django.db.utils import NotSupportedError
-from django.test import TestCase, TransactionTestCase, override_settings
+from django.test import (
+ TestCase, TransactionTestCase, override_settings, skipIfDBFeature,
+)
from django.test.utils import isolate_apps
from ..models import Author, Item, Object, Square
@@ -112,6 +114,7 @@ class SchemaTests(TransactionTestCase):
self.assertFalse(constraint_checks_enabled())
self.assertTrue(constraint_checks_enabled())
+ @skipIfDBFeature('supports_atomic_references_rename')
def test_field_rename_inside_atomic_block(self):
"""
NotImplementedError is raised when a model field rename is attempted
@@ -129,6 +132,7 @@ class SchemaTests(TransactionTestCase):
with connection.schema_editor(atomic=True) as editor:
editor.alter_field(Author, Author._meta.get_field('name'), new_field)
+ @skipIfDBFeature('supports_atomic_references_rename')
def test_table_rename_inside_atomic_block(self):
"""
NotImplementedError is raised when a table rename is attempted inside