-
-
Notifications
You must be signed in to change notification settings - Fork 59
Add tests for response model #74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report
@@ Coverage Diff @@
## add-response-model #74 +/- ##
======================================================
+ Coverage 85.63% 90.04% +4.40%
======================================================
Files 22 22
Lines 738 864 +126
======================================================
+ Hits 632 778 +146
+ Misses 106 86 -20
Continue to review full report at Codecov.
|
2f632c6
to
2252051
Compare
Sourcery Code Quality Report✅ Merging this PR will increase code quality in the affected files by 1.38%.
Here are some functions in these files that still need a tune-up:
Legend and ExplanationThe emojis denote the absolute quality of the code:
The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request. Please see our documentation here for details on how these metrics are calculated. We are actively working on this report - lots more documentation and extra metrics to come! Help us improve this quality report! |
* initial commit * tests: add fixtures for APIResponse * tests: [WIP] Test methods that don't interact with RequestResponse * tests: replace builtin type by typing type and add type annotations * tests: add requests Response fixtures * chore: change return order to improve readability * tests: add tests for left methods Co-authored-by: Joel Lee <[email protected]> Co-authored-by: Dani Reinón <[email protected]>
* add poetry dependency * create APIResponse model * return APIResponse model in execute method * sort imports * mypy bug workaround (python/mypy#9319) * split logic, validate error existance and better type APIResponse * Implement APIError * add missing black config in pre-commit config * type APIError properties * fix: rm unused code and use returning param in update * refactor: reorder lines * chore: rebuild sync * chore: rebuild poetry.lock * fix: remove wrong parameter * chore: format * Chore: add missing return types Co-authored-by: Anand <[email protected]> * chore: replace builtin dict by Dict to support python < 3.9 * chore: update precommit hooks * chore: apply format * update return type in execute method * use relative import * add link to mypy issue * switch super init by class init to avoid future errors * chore: apply future annotations notation to return * chore: rebuild sync * tests: Add tests for response model (#74) * initial commit * tests: add fixtures for APIResponse * tests: [WIP] Test methods that don't interact with RequestResponse * tests: replace builtin type by typing type and add type annotations * tests: add requests Response fixtures * chore: change return order to improve readability * tests: add tests for left methods Co-authored-by: Joel Lee <[email protected]> Co-authored-by: Dani Reinón <[email protected]> * chore: modify ValueError with ValidationError * chore: add "_" to internal methods Co-authored-by: Anand <[email protected]> Co-authored-by: Lee Yi Jie Joel <[email protected]> Co-authored-by: Joel Lee <[email protected]>
Add tests to #64