TYP: handle mypy ignore in pandas/_testing
- [ ] xref #37715
- [ ] tests added / passed
- [ ] passes `black pandas`
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry

Handle mypy ignore comments in ``pandas/_testing.py``, function ``write_to_compressed``.
It's green, except failing ``TestHDFStore.test_append_with_data_columns`` on Linux py39.