Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Avoid having helper function start with "test"
  • Loading branch information
jacobtylerwalls committed Apr 15, 2023
commit b7cbfe4a05aa0a682b6731e32cb734931d6ea5a5
4 changes: 2 additions & 2 deletions Lib/test/test_inspect.py
Original file line number Diff line number Diff line change
Expand Up @@ -4174,11 +4174,11 @@ def test(a_po, b_po, c_po=3, /, foo=42, *, bar=50, **kwargs):
with self.assertRaisesRegex(TypeError, "missing 2 required positional arguments"):
self.call(test, a_po=1, b_po=2)

def test_without_var_kwargs(a_po, b_po, c_po=3, /, foo=42, *, bar=50):
def without_var_kwargs(a_po, b_po, c_po=3, /, foo=42, *, bar=50):
return a_po, b_po, c_po, foo, bar

with self.assertRaisesRegex(TypeError, "positional-only arguments passed as keyword"):
self.call(test_without_var_kwargs, 1, 2, foo=4, bar=5, c_po=10)
self.call(without_var_kwargs, 1, 2, foo=4, bar=5, c_po=10)

def test_signature_bind_with_self_arg(self):
# Issue #17071: one of the parameters is named "self
Expand Down