Merge lp:~adiroiban/pocket-lint/1082046-json-checker into lp:pocket-lint
Status: | Merged |
---|---|
Approved by: | Curtis Hovey |
Approved revision: | 473 |
Merged at revision: | 474 |
Proposed branch: | lp:~adiroiban/pocket-lint/1082046-json-checker |
Merge into: | lp:pocket-lint |
Diff against target: |
364 lines (+245/-20) 4 files modified
pocketlint/formatcheck.py (+74/-18) pocketlint/tests/test_json.py (+123/-0) pocketlint/tests/test_restructuredtext.py (+2/-2) pocketlint/tests/test_text.py (+46/-0) |
To merge this branch: | bzr merge lp:~adiroiban/pocket-lint/1082046-json-checker |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Curtis Hovey | code | Approve | |
Review via email:
|
Description of the change
Description
===========
The is no checker for JSON files.
JSON files are text files, but since no long lines breaker is supported in JSON, long lines are accepted for JSON.
All other plain text file checks should be applied.
Changes
=======
* A mimetype was forced for JSON since on WIndows it might not be automatically recognized.
* I have enabled the checker for ReStructuredText, since at the last merge I have only created the checker but not enabled it.
* I moved the checker_
I have a few drive by changes. Let me know if you want me to move them in another merge request.
I was not sure how to test basic plain text checks for JSON, so I just added simple test.
Let me know what needs to be changed for accepting this patch.
Thanks!
Thank you. I will merge the branch.