From 6b4d013f52b241df97827cb73bd1a9d148634603 Mon Sep 17 00:00:00 2001 From: remcodraijer Date: Thu, 24 Mar 2016 12:27:57 +0100 Subject: [PATCH 1/2] Changed summary line of docstring to follow PEP 0257 Quoting https://www.python.org/dev/peps/pep-0257/#one-line-docstrings The docstring is a phrase ending in a period. It prescribes the function or method's effect as a command ("Do this", "Return that"), not as a description; e.g. don't write "Returns the pathname ...". --- docs/writing/tests.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/writing/tests.rst b/docs/writing/tests.rst index f014bfdfd..19e7ec0b6 100644 --- a/docs/writing/tests.rst +++ b/docs/writing/tests.rst @@ -116,7 +116,7 @@ A simple doctest in a function: .. code-block:: python def square(x): - """Squares x. + """Square x. >>> square(2) 4 From 02d68a86ed9a9bfce9bad6aa532646cfcbda67b6 Mon Sep 17 00:00:00 2001 From: remcodraijer Date: Thu, 24 Mar 2016 12:33:39 +0100 Subject: [PATCH 2/2] Changed summary line of docstring to follow PEP 0257 - update Quoting https://www.python.org/dev/peps/pep-0257/#one-line-docstrings "The docstring is a phrase ending in a period. It prescribes the function or method's effect as a command ("Do this", "Return that"), not as a description; e.g. don't write "Returns the pathname ...". --- docs/writing/tests.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/writing/tests.rst b/docs/writing/tests.rst index 19e7ec0b6..84e5d27db 100644 --- a/docs/writing/tests.rst +++ b/docs/writing/tests.rst @@ -116,7 +116,7 @@ A simple doctest in a function: .. code-block:: python def square(x): - """Square x. + """Return the square of x. >>> square(2) 4