Skip to content

Commit

Permalink
Remove more bits of Python < 3.8 support
Browse files Browse the repository at this point in the history
  • Loading branch information
cjwatson committed Dec 24, 2024
1 parent b12928b commit a3876f6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 16 deletions.
16 changes: 1 addition & 15 deletions fixtures/tests/_fixtures/test_popen.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,8 @@ def test_handles_all_Popen_args(self):
pass_fds="pass_fds",
encoding="encoding",
errors="errors",
text="text",
)
if sys.version_info >= (3, 7):
all_args["text"] = "text"
if sys.version_info >= (3, 9):
all_args["group"] = "group"
all_args["extra_groups"] = "extra_groups"
Expand All @@ -100,16 +99,6 @@ def get_info(proc_args):
fixture = self.useFixture(FakePopen(get_info))
fixture(**all_args)

@testtools.skipUnless(
sys.version_info < (3, 7), "only relevant on Python <3.7"
)
def test_rejects_3_7_args_on_older_versions(self):
fixture = self.useFixture(FakePopen(lambda proc_args: {}))
with testtools.ExpectedException(
TypeError, r".* got an unexpected keyword argument 'text'"
):
fixture(args="args", text=True)

@testtools.skipUnless(
sys.version_info < (3, 9), "only relevant on Python <3.9"
)
Expand Down Expand Up @@ -175,9 +164,6 @@ def test_function_signature(self):
fake_kwargs.remove('user')
fake_kwargs.remove('umask')

if sys.version_info < (3, 7):
fake_kwargs.remove('text')

self.assertSetEqual(
fake_kwargs,
real_kwargs,
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py37,py38,py39,py310,py311,py312,pypy3
envlist = py38,py39,py310,py311,py312,pypy3
minversion = 3.1

[testenv]
Expand Down

0 comments on commit a3876f6

Please sign in to comment.