mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Removed redundant model field choices tests.
This commit is contained in:
committed by
Tim Graham
parent
2ee1e1a174
commit
ea60b7bc74
@@ -162,6 +162,12 @@ class GetFieldDisplayTests(SimpleTestCase):
|
||||
self.assertEqual(Whiz(c='').get_c_display(), '') # Empty value
|
||||
self.assertEqual(WhizDelayed(c=0).get_c_display(), 'Other') # Delayed choices
|
||||
|
||||
def test_get_FIELD_display_translated(self):
|
||||
"""A translated display value is coerced to str."""
|
||||
val = Whiz(c=5).get_c_display()
|
||||
self.assertIsInstance(val, str)
|
||||
self.assertEqual(val, 'translated')
|
||||
|
||||
def test_iterator_choices(self):
|
||||
"""
|
||||
get_choices() works with Iterators.
|
||||
|
||||
Reference in New Issue
Block a user