Add typing for the functions in TestCase.
Review Request #14035 — Created July 13, 2024 and updated
This updates
TestCase
to add type hints all throughout. This helps
ensure we pass in the right typse to functions, and that we get the
right transport and client types when setting up state for API tests.
Unit tests pass.
Summary | ID |
---|---|
9ae2883847e5d422970e673033ec2840462c31be |
Description | From | Last Updated |
---|---|---|
'typing.Any' imported but unused Column: 1 Error code: F401 |
![]() |
|
redefinition of unused 'RBClient' from line 17 Column: 5 Error code: F811 |
![]() |
|
While you're here, mind adding docstrings and changing to super()? |
|
|
Here too. |
|
|
Now that we're properly using __future__.annotations, we should change from Dict to dict and List to list. |
|
|
Blank line between these two. |
|
|
Can we add a doc comment for this? |
|
|
maxDiff doesn't appear to be used anywhere within the rbtools codebase. Can we just get rid of this? |
|
|
Should probably be Any instead of object. |
|
- Change Summary:
-
Removed an unused import and a duplicate import.
- Commits:
-
Summary ID 6006d70d24e42d186300de3f86073b6b931b2b3b 9c81b7bfff3bec145667b91c415b0f60a6734587 - Diff:
-
Revision 2 (+126 -46)
Checks run (2 succeeded)
- Change Summary:
-
- Added some docstrings to the setup/teardown methods.
- Added additional type hints for class/instance variables.
- Simplified
super()
calls.
- Commits:
-
Summary ID 9c81b7bfff3bec145667b91c415b0f60a6734587 9ae2883847e5d422970e673033ec2840462c31be - Diff:
-
Revision 3 (+216 -62)