Ticket #4341: tests.py

File tests.py, 444 bytes (added by Alex Robbins, 14 years ago)

A unit test that shows this problem has been fixed

Line 
1from django.test import TestCase
2from django.forms.extras import SelectDateWidget
3
4
5class SimpleTest(TestCase):
6 def test_select_date_widget_attrs(self):
7 """
8 Ticket #4341
9 Tests that the select date widget adds attrs like other widgets.
10 """
11 date_widget = SelectDateWidget(attrs={'class': 'test-class'})
12 self.assert_(
13 'test-class' in date_widget.render(name='Test', value=None))
Back to Top