Beispiel #1
0
 def test_choices(self):
     em = EasyModel(django_databrowse.site, SomeModel)
     field = EasyField(
         em,
         models.CharField(max_length=2,
                          choices=(("a", "azerty"), ("q", "querty"))))
     self.assertEqual(len([f for f in field.choices()]), 2)
 def test_choices(self):
     em = EasyModel(django_databrowse.site, SomeModel)
     field = EasyField(
         em,
         models.CharField(max_length=2,
                          choices=(("a", "azerty"),("q","querty"))
                          )
         )
     self.assertEqual(len([f for f in field.choices()]), 2)