'Can increase the built-in forms limit via a higher max_num.'

def test_increase_hard_limit(self):

    _old_DEFAULT_MAX_NUM = formsets.DEFAULT_MAX_NUM
    try:
        formsets.DEFAULT_MAX_NUM = 3
        ChoiceFormSet = formset_factory(Choice, max_num=4)
        formset = ChoiceFormSet({u'choices-TOTAL_FORMS': u'4', u'choices-INITIAL_FORMS': u'0', u'choices-MAX_NUM_FORMS': u'4', u'choices-0-choice': u'Zero', u'choices-0-votes': u'0', u'choices-1-choice': u'One', u'choices-1-votes': u'1', u'choices-2-choice': u'Two', u'choices-2-votes': u'2', u'choices-3-choice': u'Three', u'choices-3-votes': u'3'}, prefix=u'choices')
        self.assertEqual(len(formset.forms), 4)
    finally:
        formsets.DEFAULT_MAX_NUM = _old_DEFAULT_MAX_NUM
