Actually, you can even see both examples from that sample code on the front
page there. PEP8 (http://www.python.org/dev/peps/pep-0008/#blank-lines)
states for top level functions and classes, there should be 2 blank lines
in between them. In your sample code on the page there, you only have 1.
So modifying your example code, showing the differences in brackets, here
is the corrections:
import unittest
[2nd newline]class TestOldPython(unittest.TestCase):
def test___init__(self):
# old_python = OldPython(age)
assert False []# TODO: implement your test here
def test_hiss(self):
# old_python = OldPython(age)
# self.assertEqual(expected, old_python.hiss())
assert False []# TODO: implement your test here
if __name__ == '__main__':
unittest.main()
I'll admit this is very nit-picky, but if it's being auto-generated, might
as well do it right. Besides, my VIM yells at me if there are any syntax
issues, so that gets old when I have dozens of functions/classes.
On Fri, Nov 8, 2013 at 2:29 AM, Michal Kwiatkowski <email address hidden> wrote:
> Can you give more details, what code are you running pythoscope on?
>
> If you run the example from the main page (http://pythoscope.org/) you
> won't get any of those you mentioned.
>
> ** Changed in: pythoscope
> Status: New => Incomplete
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1247664
>
> Title:
> Pythoscope should follow PEP8 layout guidelines for generated files
>
> Status in Pythoscope, the unit test generator:
> Incomplete
>
> Bug description:
> For those of us with automatic file checkers and the like, having to
> clean up and reformat many many functions in the automatically
> generated test files that fail to meet the PEP8 guidelines seems
> unnecessary. I'm specifically referring to:
>
> 1) 2 blank lines in before top level functions and classes, and imports
> and the rest of the file
> 2) 2 blank spaces before in-line comments
>
> There might be others but so far this is all I've found.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/pythoscope/+bug/1247664/+subscriptions
>
Actually, you can even see both examples from that sample code on the front www.python. org/dev/ peps/pep- 0008/#blank- lines)
page there. PEP8 (http://
states for top level functions and classes, there should be 2 blank lines
in between them. In your sample code on the page there, you only have 1.
Likewise, regarding in-line comments, PEP8 ( www.python. org/dev/ peps/pep- 0008/#inline- comments) states there
http://
should be at least 2 spaces separating the code and the comment, here you
only have one.
So modifying your example code, showing the differences in brackets, here
is the corrections:
import unittest unittest. TestCase) : init__( self):
[2nd newline]class TestOldPython(
def test___
# old_python = OldPython(age)
assert False []# TODO: implement your test here
def test_hiss(self): l(expected, old_python.hiss())
# old_python = OldPython(age)
# self.assertEqua
assert False []# TODO: implement your test here
if __name__ == '__main__':
unittest.main()
I'll admit this is very nit-picky, but if it's being auto-generated, might
as well do it right. Besides, my VIM yells at me if there are any syntax
issues, so that gets old when I have dozens of functions/classes.
Brian Clements brianclements. net <http:// www.brianclemen ts.net>
<email address hidden>
http://
On Fri, Nov 8, 2013 at 2:29 AM, Michal Kwiatkowski <email address hidden> wrote:
> Can you give more details, what code are you running pythoscope on? pythoscope. org/) you /bugs.launchpad .net/bugs/ 1247664 /bugs.launchpad .net/pythoscope /+bug/1247664/ +subscriptions
>
> If you run the example from the main page (http://
> won't get any of those you mentioned.
>
> ** Changed in: pythoscope
> Status: New => Incomplete
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https:/
>
> Title:
> Pythoscope should follow PEP8 layout guidelines for generated files
>
> Status in Pythoscope, the unit test generator:
> Incomplete
>
> Bug description:
> For those of us with automatic file checkers and the like, having to
> clean up and reformat many many functions in the automatically
> generated test files that fail to meet the PEP8 guidelines seems
> unnecessary. I'm specifically referring to:
>
> 1) 2 blank lines in before top level functions and classes, and imports
> and the rest of the file
> 2) 2 blank spaces before in-line comments
>
> There might be others but so far this is all I've found.
>
> To manage notifications about this bug go to:
> https:/
>