Skip to content

Commit

Permalink
fix warning
Browse files Browse the repository at this point in the history
  • Loading branch information
giampaolo committed Jun 21, 2024
1 parent df3077f commit 52eaa56
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions pyftpdlib/test/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ def test_write_opt(self):
main(["-w", "-p", "0"])

with warnings.catch_warnings():
warnings.filterwarnings("ignore")
ftpd = main(["-w", "-p", "0"])
perms = ftpd.handler.authorizer.get_perms("anonymous")
assert (
Expand All @@ -85,8 +86,9 @@ def test_write_opt(self):
)

# unexpected argument
with pytest.raises(SystemExit):
main(["-w", "foo", "-p", "0"])
with warnings.catch_warnings():
with pytest.raises(SystemExit):
main(["-w", "foo", "-p", "0"])

def test_directory_opt(self):
dirname = self.get_testfn()
Expand Down

0 comments on commit 52eaa56

Please sign in to comment.