mirror of
https://github.com/django/django.git
synced 2025-09-26 20:19:16 +00:00
Fixed backends.oracle.test_operations.
Using unittest.TestCase doesn't work properly when we perform db
queries. Moreover introspection is extremely slow on Oracle without
limiting models to a "backends" app.
Follow up to 8bcca47e83
.
This commit is contained in:
parent
150c3d13a6
commit
d5898db50e
1 changed files with 3 additions and 1 deletions
|
@ -2,12 +2,14 @@ import unittest
|
||||||
|
|
||||||
from django.core.management.color import no_style
|
from django.core.management.color import no_style
|
||||||
from django.db import connection
|
from django.db import connection
|
||||||
|
from django.test import TransactionTestCase
|
||||||
|
|
||||||
from ..models import Person, Tag
|
from ..models import Person, Tag
|
||||||
|
|
||||||
|
|
||||||
@unittest.skipUnless(connection.vendor == 'oracle', 'Oracle tests')
|
@unittest.skipUnless(connection.vendor == 'oracle', 'Oracle tests')
|
||||||
class OperationsTests(unittest.TestCase):
|
class OperationsTests(TransactionTestCase):
|
||||||
|
available_apps = ['backends']
|
||||||
|
|
||||||
def test_sequence_name_truncation(self):
|
def test_sequence_name_truncation(self):
|
||||||
seq_name = connection.ops._get_no_autofield_sequence_name('schema_authorwithevenlongee869')
|
seq_name = connection.ops._get_no_autofield_sequence_name('schema_authorwithevenlongee869')
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue