Skip to content

Commit edfed65

Browse files
committed
fix: revert bad factor
Signed-off-by: Élie Goudout <[email protected]>
1 parent 656dc3d commit edfed65

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/paramclasses/test_signature.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,17 +153,19 @@ def test_signature_call_non_unpackable(
153153

154154
accepts_args = pos_only or pos_or_kw or var_pos
155155
accepts_kwargs = pos_or_kw or kw_only or var_kw
156-
# >=3.15.0a2-compatible message (python/cpython/pull/136395)
157-
msg = " after * must be an iterable, not NoneType"
158156

159157
# Non-unpackable ``args``
160158
if accepts_args:
159+
# >=3.15.0a2-compatible message (python/cpython/pull/136395)
160+
msg = " after * must be an iterable, not NoneType"
161161
args_kwargs = [None, {}] if accepts_kwargs else [None]
162162
with pytest.raises(TypeError, match=f"{re.escape(msg)}$"):
163163
ParamWithPostInit(*args_kwargs)
164164

165165
# Non-unpackable ``kwargs``
166166
if accepts_kwargs:
167+
# >=3.15.0a2-compatible message (python/cpython/pull/136395)
168+
msg = " after ** must be a mapping, not NoneType"
167169
args_kwargs = [[], None] if accepts_args else [None]
168170
with pytest.raises(TypeError, match=f"{re.escape(msg)}$"):
169171
ParamWithPostInit(*args_kwargs)

0 commit comments

Comments
 (0)