2014-03-14 22:18:20 +00:00
|
|
|
from django.db import connection
|
2015-08-12 13:26:57 +00:00
|
|
|
from django.test import SimpleTestCase
|
2014-04-12 03:58:56 +00:00
|
|
|
|
2015-08-12 13:26:57 +00:00
|
|
|
from .fields import CustomTypedField
|
2014-04-12 03:58:56 +00:00
|
|
|
|
2014-03-14 22:18:20 +00:00
|
|
|
|
2015-04-17 21:38:20 +00:00
|
|
|
class TestDbType(SimpleTestCase):
|
2014-03-14 22:18:20 +00:00
|
|
|
|
|
|
|
def test_db_parameters_respects_db_type(self):
|
|
|
|
f = CustomTypedField()
|
|
|
|
self.assertEqual(f.db_parameters(connection)['type'], 'custom_field')
|