Skip to content

Commit 13e5dc9

Browse files
refer the node-from-parent deprecation documentation in the warning
1 parent 442f7a7 commit 13e5dc9

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/_pytest/deprecated.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,10 @@
3636

3737
NODE_USE_FROM_PARENT = UnformattedWarning(
3838
PytestDeprecationWarning,
39-
"direct construction of {name} has been deprecated, please use {name}.from_parent",
39+
"Direct construction of {name} has been deprecated, please use {name}.from_parent.\n"
40+
"See "
41+
"https://docs.pytest.org/en/latest/deprecations.html#node-construction-changed-to-node-from-parent"
42+
" for more details.",
4043
)
4144

4245
JUNIT_XML_DEFAULT_FAMILY = PytestDeprecationWarning(

0 commit comments

Comments
 (0)