mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-07 21:44:18 +00:00
parent
c9cac9957b
commit
0c62569c4f
7 changed files with 0 additions and 64 deletions
|
|
@ -25,14 +25,6 @@ def test_to_argparse():
|
|||
assert isinstance(kwargs["type"], functools.partial)
|
||||
|
||||
|
||||
def test_to_optparse():
|
||||
"""Test that .to_optparse() produces a useful error message."""
|
||||
with pytest.raises(AttributeError) as excinfo:
|
||||
manager.Option("--foo").to_optparse
|
||||
(msg,) = excinfo.value.args
|
||||
assert msg == "to_optparse: flake8 now uses argparse"
|
||||
|
||||
|
||||
def test_to_argparse_creates_an_option_as_we_expect():
|
||||
"""Show that we pass all keyword args to argparse."""
|
||||
opt = manager.Option("-t", "--test", action="count")
|
||||
|
|
|
|||
|
|
@ -160,15 +160,6 @@ def test_normalize_paths(value, expected):
|
|||
assert utils.normalize_paths(value) == expected
|
||||
|
||||
|
||||
def test_is_windows_checks_for_nt():
|
||||
"""Verify that we correctly detect Windows."""
|
||||
with mock.patch.object(os, "name", "nt"):
|
||||
assert utils.is_windows() is True
|
||||
|
||||
with mock.patch.object(os, "name", "posix"):
|
||||
assert utils.is_windows() is False
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"filename,patterns,expected",
|
||||
[
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue