Get rid of deprecated pytest.warns(None) usage
#38027
+11
−5
Merged