def test_registration_form_subclass_is_valid_for_django_18(self):
        """
        Test that ``RegistrationForm`` subclasses can save in
        Django > 1.8

        """
        if DJANGO_VERSION >= StrictVersion('1.8'):
            data = {'new_field': 'custom username',
                    'email': 'foo@example.com',
                    'password1': 'foo',
                    'password2': 'foo'}

            form = forms.RegistrationForm(data=data)

            self.assertTrue(form.is_valid())
dataset/ETHPy150Open macropin/django-registration/registration/tests/forms_custom_user.py/RegistrationFormTests.test_registration_form_subclass_is_valid_for_django_18/original