-
-
Notifications
You must be signed in to change notification settings - Fork 223
Add flake8-pytest-style (PT) for ruff #1105
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 ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1105 +/- ##
==========================================
+ Coverage 92.58% 92.60% +0.01%
==========================================
Files 96 96
Lines 6072 6084 +12
Branches 1496 1502 +6
==========================================
+ Hits 5622 5634 +12
Misses 351 351
Partials 99 99 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This will catch common issues with pytest code. * Use `match` when using `pytest.raises()` for base exception types like `TypeError` or `ValueError` * Use tuples for `parametrize()` * Enforces `pytest.raises()` to contain simple statements, using `noqa` to skip this on some cases for now. * Fixes incorrect exception type (valueerror instead of typeerror) for iotdimmer. * Adds check valid types for `iotbulb.set_hsv` and `color` smart module. * Consolidate exception messages for common interface modules.
## [0.7.2](https://github.com/python-kasa/python-kasa/tree/0.7.2) (2024-08-30) [Full Changelog](0.7.1...0.7.2) **Release summary:** - **Breaking** change to disable including the check for the latest firmware for tapo devices and newer kasa devices in the standard update cycle. To check for the latest firmware call `check_latest_firmware` on the firmware module or run the `check_latest_firmware` feature. - Minor bugfixes and improvements. **Breaking changes:** - Disable automatic updating of latest firmware [\#1103](#1103) (@sdb9696) **Implemented enhancements:** - Improve performance of dict merge code [\#1097](#1097) (@bdraco) **Fixed bugs:** - Fix logging in iotdevice when a module is module not supported [\#1100](#1100) (@bdraco) **Documentation updates:** - Fix incorrect docs link in contributing.md [\#1099](#1099) (@sdb9696) **Project maintenance:** - Add flake8-pytest-style \(PT\) for ruff [\#1105](#1105) (@rytilahti) - Add flake8-logging \(LOG\) and flake8-logging-format \(G\) for ruff [\#1104](#1104) (@rytilahti) - Add missing typing\_extensions dependency [\#1101](#1101) (@sdb9696) - Remove top level await xdoctest fixture [\#1098](#1098) (@sdb9696) - Enable python 3.13, allow pre-releases for CI [\#1086](#1086) (@rytilahti)
This will catch common issues with pytest code.
match
when usingpytest.raises()
for base exception types likeTypeError
orValueError
parametrize()
pytest.raises()
to contain simple statements, usingnoqa
to skip this on some cases for now.iotbulb.set_hsv
andcolor
smart module.