1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

[soc2009/multidb] Merged up to trunk r11810. There are many conflicts in this merge, these will be resolved in a subsequent commit.

git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11812 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Alex Gaynor
2009-12-12 02:10:28 +00:00
parent 353e079792
commit c88113683d
34 changed files with 1239 additions and 233 deletions

View File

@@ -1,7 +1,11 @@
# -*- coding: utf-8 -*-
# Unit and doctests for specific database backends.
import unittest
<<<<<<< HEAD:tests/regressiontests/backends/tests.py
from django.db import backend, connection, DEFAULT_DB_ALIAS
=======
from django.db import backend, connection
>>>>>>> master:tests/regressiontests/backends/tests.py
from django.db.backends.signals import connection_created
from django.conf import settings
@@ -10,7 +14,11 @@ class Callproc(unittest.TestCase):
def test_dbms_session(self):
# If the backend is Oracle, test that we can call a standard
# stored procedure through our cursor wrapper.
<<<<<<< HEAD:tests/regressiontests/backends/tests.py
if settings.DATABASES[DEFAULT_DB_ALIAS]['ENGINE'] == 'django.db.backends.oracle':
=======
if settings.DATABASE_ENGINE == 'oracle':
>>>>>>> master:tests/regressiontests/backends/tests.py
convert_unicode = backend.convert_unicode
cursor = connection.cursor()
cursor.callproc(convert_unicode('DBMS_SESSION.SET_IDENTIFIER'),
@@ -24,7 +32,11 @@ class LongString(unittest.TestCase):
def test_long_string(self):
# If the backend is Oracle, test that we can save a text longer
# than 4000 chars and read it properly
<<<<<<< HEAD:tests/regressiontests/backends/tests.py
if settings.DATABASES[DEFAULT_DB_ALIAS]['ENGINE'] == 'django.db.backends.oracle':
=======
if settings.DATABASE_ENGINE == 'oracle':
>>>>>>> master:tests/regressiontests/backends/tests.py
c = connection.cursor()
c.execute('CREATE TABLE ltext ("TEXT" NCLOB)')
long_str = ''.join([unicode(x) for x in xrange(4000)])