diff --git a/tests/test_ext_napoleon_docstring.py b/tests/test_ext_napoleon_docstring.py index 35e2f36bd..14929bc0d 100644 --- a/tests/test_ext_napoleon_docstring.py +++ b/tests/test_ext_napoleon_docstring.py @@ -1078,6 +1078,22 @@ Methods: options={'noindex': True})) self.assertEqual(expected, actual) + def test_keywords_with_types(self): + docstring = """\ +Do as you please + +Keyword Args: + gotham_is_yours (None): shall interfere. +""" + actual = str(GoogleDocstring(docstring)) + expected = """\ +Do as you please + +:keyword gotham_is_yours: shall interfere. +:kwtype gotham_is_yours: None +""" + self.assertEqual(expected, actual) + class NumpyDocstringTest(BaseDocstringTest): docstrings = [( @@ -2191,22 +2207,6 @@ definition_after_normal_text : int actual = str(NumpyDocstring(docstring, config)) self.assertEqual(expected, actual) - def test_keywords_with_types(self): - docstring = """\ -Do as you please - -Keyword Args: - gotham_is_yours (None): shall interfere. -""" - actual = str(GoogleDocstring(docstring)) - expected = """\ -Do as you please - -:keyword gotham_is_yours: shall interfere. -:kwtype gotham_is_yours: None -""" - self.assertEqual(expected, actual) - @contextmanager def warns(warning, match): match_re = re.compile(match)