FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[3.12] gh-106368: Increase Argument Clinic test coverage for IndentStack (GH-106933) by miss-islington · Pull Request #106943 · python/cpython · GitHub

/ cpython Public
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .py  (1) All 1 file type selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
19 changes: 19 additions & 0 deletions Lib/test/test_clinic.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -1035,6 +1035,25 @@ def test_function_not_at_column_0(self):
Nested docstring here, goeth.
""")

def test_indent_stack_no_tabs(self):
out = self.parse_function_should_fail("""
module foo
foo.bar
*vararg1: object
\t*vararg2: object
""")
msg = "Tab characters are illegal in the Clinic DSL."
self.assertIn(msg, out)

def test_indent_stack_illegal_outdent(self):
out = self.parse_function_should_fail("""
module foo
foo.bar
a: object
b: object
""")
self.assertIn("Illegal outdent", out)

def test_directive(self):
c = FakeClinic()
parser = DSLParser(c)
Expand Down

Back | FazBrowse Home | New Git URL