Ticket #10153: related_field_lookup_patch_1_test.diff
File related_field_lookup_patch_1_test.diff, 755 bytes (added by , 16 years ago) |
---|
-
tests/regressiontests/model_regress/tests.py
1 from django.test import TestCase 2 3 class RelatedModelOrderedLookupTest(TestCase): 4 """Regression test for #10153""" 5 def test_related_gte_lookup(self): 6 from models import Worker 7 8 # The bug is that the following query raises 9 # "TypeError: Related Field has invalid lookup: gte" 10 Worker.objects.filter(department__gte=0) 11 12 def test_related_lte_lookup(self): 13 from models import Worker 14 15 Worker.objects.filter(department__lte=0)