docs: replace deprecated py.test command with pytest across docs#1049
docs: replace deprecated py.test command with pytest across docs#1049TejasAmle wants to merge 1 commit into
py.test command with pytest across docs#1049Conversation
The py.test command alias has been deprecated in favour of pytest since pytest 4.0 (2018). Updated all 14 occurrences across README, example READMEs, and documentation source files to use the current pytest command instead.
📝 WalkthroughWalkthroughThis pull request updates command-line examples throughout the project documentation to use Changespy.test to pytest command migration
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@example/grpc/README.md`:
- Line 29: Replace remaining deprecated "py.test" usages with "pytest": update
the test invocation in tox-integration.ini (the entry currently running "py.test
...") to "pytest ..." and update the CLI/help text in tavern/entry.py (the
string that says "py.test --help") to "pytest --help"; ensure you change only
the command text and keep surrounding formatting and arguments intact.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: ec650d2f-3ffc-4a3c-8d60-501f61326baf
📒 Files selected for processing (10)
README.mddocs/source/basics.mddocs/source/core_concepts/config.mddocs/source/core_concepts/external_code.mddocs/source/core_concepts/marks.mddocs/source/core_concepts/types.mddocs/source/debugging.mddocs/source/examples.mdexample/grpc/README.mdexample/mqtt/README.md
| 2. In another terminal, run the tests: | ||
| ```bash | ||
| py.test -v | ||
| pytest -v |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Search for remaining py.test references in non-markdown files
echo "=== Remaining py.test references in Python files ==="
rg -n 'py\.test' --type=py
echo -e "\n=== Remaining py.test references in config/ini files ==="
rg -n 'py\.test' -g '*.ini' -g '*.cfg'
echo -e "\n=== Remaining py.test references in YAML files ==="
rg -n 'py\.test' --type=yamlRepository: taverntesting/tavern
Length of output: 457
Update remaining py.test usages in config and CLI help to pytest
tox-integration.ini:42still runspy.test ...; switch topytest ...to avoid deprecated behaviour and potential breakage.tavern/entry.py:13still tells users to runpy.test --help; update topytest --help.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@example/grpc/README.md` at line 29, Replace remaining deprecated "py.test"
usages with "pytest": update the test invocation in tox-integration.ini (the
entry currently running "py.test ...") to "pytest ..." and update the CLI/help
text in tavern/entry.py (the string that says "py.test --help") to "pytest
--help"; ensure you change only the command text and keep surrounding formatting
and arguments intact.
What
Replaces all 14 occurrences of the deprecated
py.testcommand with the currentpytestcommand across the README, example READMEs, and documentation source files.Why
The
py.testentry-point alias was deprecated in pytest 4.0 (released 2018) in favour of thepytestcommand. Usingpy.testin docs can confuse new users who follow the official pytest documentation, which exclusively usespytest.Files changed
README.md– quickstart code blockdocs/source/basics.md– file path regex exampledocs/source/debugging.md– debug run exampledocs/source/examples.md– running tests exampledocs/source/core_concepts/config.md– global config examples and the note abouttavern-cibeing an alias forpytest(notpy.test)docs/source/core_concepts/external_code.md– PYTHONPATH exampledocs/source/core_concepts/marks.md– mark filter examplesdocs/source/core_concepts/types.md– strict mode exampleexample/grpc/README.md– gRPC example instructionsexample/mqtt/README.md– MQTT example instructionsVerification
After the change, a grep across all
.mdfiles returns no remainingpy.testoccurrences.Summary by CodeRabbit
pytestcommand syntax instead of the deprecatedpy.testalias. Changes include configuration, debugging, marks, types, external code, and example project documentation.