Aim for minimal diffs in comments

This commit is contained in:
Sajith Sasidharan 2020-08-26 09:39:24 -04:00
parent 82ee45c1ac
commit 25f1a41886

View File

@ -704,9 +704,8 @@ class MultiFormatResourceTests(TrialTestCase):
def test_select_format(self): def test_select_format(self):
""" """
The ``formatArgument`` attribute of a ``MultiFormatResource`` The ``formatArgument`` attribute of a ``MultiFormatResource`` subclass
subclass identifies the query argument which selects the identifies the query argument which selects the result format.
result format.
""" """
resource = self.resource() resource = self.resource()
resource.formatArgument = "foo" resource.formatArgument = "foo"
@ -715,8 +714,8 @@ class MultiFormatResourceTests(TrialTestCase):
def test_default_format_argument(self): def test_default_format_argument(self):
""" """
If a ``MultiFormatResource`` subclass does not set If a ``MultiFormatResource`` subclass does not set ``formatArgument``
``formatArgument`` then the ``t`` argument is used. then the ``t`` argument is used.
""" """
resource = self.resource() resource = self.resource()
self.assertEqual("a", self.render(resource, t=["a"])) self.assertEqual("a", self.render(resource, t=["a"]))
@ -724,9 +723,8 @@ class MultiFormatResourceTests(TrialTestCase):
def test_no_format(self): def test_no_format(self):
""" """
If no value is given for the format argument and no default If no value is given for the format argument and no default format has
format has been defined, the base rendering behavior is used been defined, the base rendering behavior is used (``render_HTML``).
(``render_HTML``).
""" """
resource = self.resource() resource = self.resource()
self.assertEqual("html", self.render(resource)) self.assertEqual("html", self.render(resource))
@ -734,9 +732,9 @@ class MultiFormatResourceTests(TrialTestCase):
def test_default_format(self): def test_default_format(self):
""" """
If no value is given for the format argument and the If no value is given for the format argument and the ``MultiFormatResource``
``MultiFormatResource`` subclass defines a ``formatDefault``, subclass defines a ``formatDefault``, that value is used as the format
that value is used as the format to render. to render.
""" """
resource = self.resource() resource = self.resource()
resource.formatDefault = "b" resource.formatDefault = "b"
@ -745,8 +743,8 @@ class MultiFormatResourceTests(TrialTestCase):
def test_explicit_none_format_renderer(self): def test_explicit_none_format_renderer(self):
""" """
If a format is selected which has a renderer set to ``None``, If a format is selected which has a renderer set to ``None``, the base
the base rendering behavior is used (``render_HTML``). rendering behavior is used (``render_HTML``).
""" """
resource = self.resource() resource = self.resource()
resource.render_FOO = None resource.render_FOO = None