Enforce that test cases extend from correct TestCase (#67819)
Summary:
Addresses https://github.com/pytorch/pytorch/issues/66903
Main code is in torch/testing/_internal/common_utils.py and everything else is fixing the lint
Pull Request resolved: https://github.com/pytorch/pytorch/pull/67819
Reviewed By: H-Huang
Differential Revision: D32259978
Pulled By: janeyx99
fbshipit-source-id: 39c5ffbaa510e1e533d6bdacf5c6158a3dd9885d