[3.12] gh-121571: Do not use EnvironmentError in tests, use OSError instead (GH-121572) (#121575)

gh-121571: Do not use `EnvironmentError` in tests, use `OSError` instead (GH-121572)
(cherry picked from commit e2822360da)

Co-authored-by: sobolevn <mail@sobolevn.me>
This commit is contained in:
Miss Islington (bot) 2024-07-10 12:35:29 +02:00 committed by GitHub
parent ac4276cc7a
commit e47fec034e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View file

@ -1407,7 +1407,7 @@ class ProcessTestCase(BaseTestCase):
t = threading.Thread(target=open_fds)
t.start()
try:
with self.assertRaises(EnvironmentError):
with self.assertRaises(OSError):
subprocess.Popen(NONEXISTING_CMD,
stdin=subprocess.PIPE,
stdout=subprocess.PIPE,