I would have written the test simply like this:
```python
    def test_custom_empty_values(self):
        """
        Test that form fields can customize what is considered as an empty value
        for themselves (#19997).
        """
        class CustomJSONField(CharField):
            empty_values = [None, '']
            def to_python(self, value):
                # Fake json.loads
                if value == '{}':
                    return {}
                return super(CustomJSONField, self).to_python(value)

        class JSONForm(forms.Form):
            json = CustomJSONField()

        form = JSONForm(data={'json': '{}'});
        form.full_clean()
        self.assertEqual(form.cleaned_data, {'json' : {}})
```
Would this be OK for you, or did I miss something important in your version?