Deprecate conversion utilities (#78957)
* Deprecate utilities * Deprecate distance and speed * Add tests * Adjust pylint * Simplify temperature deprecation
This commit is contained in:
parent
3b05bb5b3a
commit
9c3b40dad1
11 changed files with 79 additions and 25 deletions
|
@ -17,6 +17,12 @@ INVALID_SYMBOL = "bob"
|
|||
VALID_SYMBOL = VOLUME_LITERS
|
||||
|
||||
|
||||
def test_raise_deprecation_warning(caplog: pytest.LogCaptureFixture) -> None:
|
||||
"""Ensure that a warning is raised on use of convert."""
|
||||
assert volume_util.convert(2, VOLUME_LITERS, VOLUME_LITERS) == 2
|
||||
assert "use unit_conversion.VolumeConverter instead" in caplog.text
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"function_name, value, expected",
|
||||
[
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue