-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29 from i-aki-y/support-append-config
Add a support of `--append-config`
- Loading branch information
Showing
10 changed files
with
54 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
d = {"a" : 1} # E203 | ||
|
||
|
||
def a_long_name_function_definition(x="this is a test for", y="--max-line-length setting."): # E501 | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[tool.flake8] | ||
extend-ignore = ["E203"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[flake8] | ||
max-line-length = 120 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[flake8] | ||
extend-ignore = E203 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import sys | ||
import unittest | ||
import pflake8 | ||
|
||
|
||
class TestAppendConfig(unittest.TestCase): | ||
def test_append_config_toml(self): | ||
sys.argv = [ | ||
"pflake8", | ||
"--config", | ||
"./test/data/setup.cfg", | ||
"--append-config", | ||
"./test/data/pyproject.toml", | ||
"./test/data/dummy.py", | ||
] | ||
|
||
pflake8.main() # OK if this raises no exception. | ||
|
||
def test_append_config_normal(self): | ||
sys.argv = [ | ||
"pflake8", | ||
"--config", | ||
"./test/data/setup.cfg", | ||
"--append-config", | ||
"./test/data/setup_custom.cfg", | ||
"./test/data/dummy.py", | ||
] | ||
|
||
pflake8.main() # OK if this raises no exception. | ||
|
||
|
||
if __name__ == '__main__': | ||
unittest.main() |