def METHOD_NAME(self):
    """
    Test that with deactivated registration no users can register
    """
    with self.settings(
        WGER_SETTINGS={
            'USE_RECAPTCHA': False,
            'ALLOW_GUEST_USERS': True,
            'ALLOW_REGISTRATION': False,
            'MIN_ACCOUNT_AGE_TO_TRUST': 21,
        }
    ):
        # Fetch the registration page
        response = self.client.get(reverse('core:user:registration'))
        self.assertEqual(response.status_code, 302)
        # Fill in the registration form
        registration_data = {
            'username': 'myusername',
            'password1': 'Xee4fuev1ohj',
            'password2': 'Xee4fuev1ohj',
            'email': 'my.email@example.com',
            'g-recaptcha-response': 'PASSED',
        }
        count_before = User.objects.count()
        response = self.client.post(reverse('core:user:registration'), registration_data)
        count_after = User.objects.count()
        self.assertEqual(response.status_code, 302)
        self.assertEqual(count_before, count_after)