tests.py 348 B

12345678910111213
  1. from __future__ import unicode_literals
  2. from django.db import connection
  3. from django.test import SimpleTestCase
  4. from .fields import CustomTypedField
  5. class TestDbType(SimpleTestCase):
  6. def test_db_parameters_respects_db_type(self):
  7. f = CustomTypedField()
  8. self.assertEqual(f.db_parameters(connection)['type'], 'custom_field')