mirror of
https://github.com/django/django.git
synced 2024-12-27 03:25:58 +00:00
10 lines
335 B
Python
10 lines
335 B
Python
|
from django.test import TestCase
|
||
|
from models import ResolveThis
|
||
|
|
||
|
class DeferRegressionTest(TestCase):
|
||
|
def test_resolve_columns(self):
|
||
|
rt = ResolveThis.objects.create(num=5.0, name='Foobar')
|
||
|
qs = ResolveThis.objects.defer('num')
|
||
|
self.assertEqual(1, qs.count())
|
||
|
self.assertEqual('Foobar', qs[0].name)
|