99 "version, expected" ,
1010 [
1111 (
12- 11 ,
13- "Old thing is deprecated and will be removed in Pillow 11 "
14- r"\(2024 -10-15\)\. Use new thing instead\." ,
12+ 12 ,
13+ "Old thing is deprecated and will be removed in Pillow 12 "
14+ r"\(2025 -10-15\)\. Use new thing instead\." ,
1515 ),
1616 (
1717 None ,
@@ -54,18 +54,18 @@ def test_old_version(deprecated: str, plural: bool, expected: str) -> None:
5454
5555def test_plural () -> None :
5656 expected = (
57- r"Old things are deprecated and will be removed in Pillow 11 \(2024 -10-15\)\. "
57+ r"Old things are deprecated and will be removed in Pillow 12 \(2025 -10-15\)\. "
5858 r"Use new thing instead\."
5959 )
6060 with pytest .warns (DeprecationWarning , match = expected ):
61- _deprecate .deprecate ("Old things" , 11 , "new thing" , plural = True )
61+ _deprecate .deprecate ("Old things" , 12 , "new thing" , plural = True )
6262
6363
6464def test_replacement_and_action () -> None :
6565 expected = "Use only one of 'replacement' and 'action'"
6666 with pytest .raises (ValueError , match = expected ):
6767 _deprecate .deprecate (
68- "Old thing" , 11 , replacement = "new thing" , action = "Upgrade to new thing"
68+ "Old thing" , 12 , replacement = "new thing" , action = "Upgrade to new thing"
6969 )
7070
7171
@@ -78,16 +78,16 @@ def test_replacement_and_action() -> None:
7878)
7979def test_action (action : str ) -> None :
8080 expected = (
81- r"Old thing is deprecated and will be removed in Pillow 11 \(2024 -10-15\)\. "
81+ r"Old thing is deprecated and will be removed in Pillow 12 \(2025 -10-15\)\. "
8282 r"Upgrade to new thing\."
8383 )
8484 with pytest .warns (DeprecationWarning , match = expected ):
85- _deprecate .deprecate ("Old thing" , 11 , action = action )
85+ _deprecate .deprecate ("Old thing" , 12 , action = action )
8686
8787
8888def test_no_replacement_or_action () -> None :
8989 expected = (
90- r"Old thing is deprecated and will be removed in Pillow 11 \(2024 -10-15\)"
90+ r"Old thing is deprecated and will be removed in Pillow 12 \(2025 -10-15\)"
9191 )
9292 with pytest .warns (DeprecationWarning , match = expected ):
93- _deprecate .deprecate ("Old thing" , 11 )
93+ _deprecate .deprecate ("Old thing" , 12 )
0 commit comments