Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
1 change: 1 addition & 0 deletions changelog/3870.doc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
correct documentation for setuptools integration
2 changes: 1 addition & 1 deletion doc/en/goodpractices.rst
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ your own setuptools Test command for invoking pytest.
setup(
# ...,
tests_require=["pytest"],
cmdclass={"test": PyTest},
cmdclass={"pytest": PyTest},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this string ("test"/"pytest") the name of the command executed in the next section?

python setup.py test

Copy link
Contributor Author

@schmamps schmamps Aug 24, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Earlier in the document, 'test' is created as an alias to 'pytest':

[aliases]
test=pytest

The command doesn't work unless you remove this from setup.cfg or replace that alias with the canonical name in setup.py.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahh right, thanks for the clarification! 👍

)

Now if you run::
Expand Down