-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Leverage
__subclasses__()
to improve test configs
Summary: Current tests on the configs with subclasses relied on explicit instantiating subclasses to test it. There are some limitations on this approach: 1. It is hard to catch newly added subclasses. 2. Due to some unknown interactions with `typing.Generic`, [the current `buck` test discovery mechanism is not able to discover the tests in it](#64 (comment)). To resolve this, this diff refactors those tests with [`type.__subclasses()`](https://docs.python.org/3/reference/datamodel.html#type.__subclasses__) to tests the configs with subclasses. Differential Revision: D67652761
- Loading branch information
1 parent
3b8a3a6
commit c758179
Showing
1 changed file
with
23 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters