We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a8f109c commit fffa6ceCopy full SHA for fffa6ce
test/deprecation/test_various.py
@@ -4,6 +4,7 @@
4
"""Tests of assorted deprecation warnings with no extra subtleties to check."""
5
6
import gc
7
+import warnings
8
9
import pytest
10
@@ -25,5 +26,14 @@ def single_diff(tmp_path):
25
26
27
28
def test_diff_renamed_warns(single_diff):
29
+ """The deprecated Diff.renamed property issues a deprecation warning."""
30
with pytest.deprecated_call():
31
single_diff.renamed
32
+
33
34
+def test_diff_renamed_file_does_not_warn(single_diff):
35
+ """The preferred Diff.renamed_file property issues no deprecation warning."""
36
+ with warnings.catch_warnings():
37
+ # FIXME: Refine this to filter for deprecation warnings from GitPython.
38
+ warnings.simplefilter("error", DeprecationWarning)
39
+ single_diff.renamed_file
0 commit comments