flake8
-
extension/tests/runtests.py (Diff revision 1) Show all issues -
-
-
-
-
-
-
-
-
-
Review Request #11237 — Created Oct. 21, 2020 and updated
Information | |
---|---|
jace | |
ReviewBot | |
master | |
b0dbd60... | |
Reviewers | |
reviewbot | |
ceciliawei, jblazusi |
Fixed comment length (changed to 70 characters)
Added .nosids and .test_notes to .gitignore (Note: I'm hoping I did it properly. I may have only added the file name and not a path so please let me know if I messed up).
Moved all subclasses from the previous runtests.py file into their own files.
Added more empty function definitions in the new files that match the tests I have planned for that file.
Also, I'm assuming I'm going to have flake8 errors again. I'm not exactly sure how to execute "flake8 --ignore E121,E125,E129,E241 --max-line-length 79 PATH" locally as it gives me an error in my terminal. If anyone knows what I'm doing wrong please let me know.
Description | From | Last Updated |
---|---|---|
Can you wrap the description to ~70 (upwards of 75) characters per row? That's the standard for the description wrapping. … |
|
|
This file is auto-generated and shouldn't be part of your commit. Let's remove it from this and instead add .noseids … |
|
|
Rather than call this runtests.py and have this shebang (which indicates that it should be run as a script), let's … |
|
|
The top-level module name is reviewbotext (ReviewBot and extension are just directories in the source). So these should be: from … |
|
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E999 SyntaxError: invalid syntax |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 0 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E101 indentation contains mixed spaces and tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
E999 IndentationError: unexpected indent |
![]() |
|
E113 unexpected indentation |
![]() |
|
E101 indentation contains mixed spaces and tabs |
![]() |
|
E115 expected an indented block (comment) |
![]() |
|
E112 expected an indented block |
![]() |
|
E101 indentation contains mixed spaces and tabs |
![]() |
|
E303 too many blank lines (2) |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
E303 too many blank lines (2) |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
E303 too many blank lines (2) |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
E303 too many blank lines (2) |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
E303 too many blank lines (2) |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
W191 indentation contains tabs |
![]() |
|
E265 block comment should start with '# ' |
![]() |
|
E302 expected 2 blank lines, found 1 |
![]() |
|
E999 SyntaxError: invalid syntax |
![]() |
|
E101 indentation contains mixed spaces and tabs |
![]() |
flake8 --ignore E121,E125,E129,E241 --max-line-length 79 PATH
before publishing the review. That should save you some time.extension/tests/.noseids (Diff revision 1) |
---|
This file is auto-generated and shouldn't be part of your commit. Let's remove it from this and instead add
.noseids
to the top-level.gitignore
file.
extension/tests/runtests.py (Diff revision 1) |
---|
Rather than call this runtests.py and have this shebang (which indicates that it should be run as a script), let's just have a
tests/
directory with a handful of files in it for each major section, liketests/test_integration.py
,tests/test_resources.py
, etc. Each of those files will be auto-discovered by the test runner.
extension/tests/runtests.py (Diff revision 1) |
---|
The top-level module name is
reviewbotext
(ReviewBot
andextension
are just directories in the source). So these should be:from reviewbotext.extension import ReviewBotExtension from reviewbotext.integration import ReviewBotIntegration
I noticed that your methods are defined as
def setUP(self)
, however, I think that PEP 8, which is largely what Review Board follows uses function names with lowercase letters and underscores to separate, rather than camelCase. Correct me if I am wrong, but I think it should bedef set_up(self)
[WIP] Implemented review feedback and expanded on structure of the testing suite (this is the post that I messed up last week)
Description: |
|
||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Commit: |
|
||||||||||||||||||||||||||||||||||||
Diff: |
Revision 2 (+76361) |
Warning: Showing 30 of 64 failures.
One suggestion as far as approach: you seem to be going for a breadth-first implementation, creating empty test case classes and methods for every possible thing. Planning is good, but for the code it's probably going to be better if you focus on a depth-first approach, getting a single test case implemented and working, and then building on that.