Consolidate the separate README.v2.md and docs/ pytest-examples tests
into a single unified test using `find_examples("README.v2.md", "docs/")`.
Add skip tags to pre-existing code blocks that aren't self-contained:
- migration.md: all blocks (before/after migration patterns)
- experimental/*.md: all blocks (experimental API patterns)
- testing.md: test blocks (reference local server module)
- README.v2.md: 4 context-dependent snippets
Every Python code block in docs pages is now both linted and executed
by pytest-examples.
- Make all concepts.md examples self-contained with proper imports
- Add test_docs_examples_run that executes every doc code block
- Use __name__ override to prevent `if __name__ == "__main__"` blocks
from starting servers during tests
- Support skip-run/skip-lint prefix tags for future use
- Drop snippet-source from quickstart.md so the example is
self-contained
- Add docs/quickstart.md and docs/concepts.md to pytest-examples so
all code blocks in documentation are linted by ruff
- Fix f-string in concepts.md Prompts example that contained backticks
causing a syntax error when parsed standalone
Update all FastMCP examples to use mcp.server.fastmcp instead of fastmcp.
Add tests to verify example servers work correctly.
Changes:
- Update import paths in all example files
- Create test_examples.py to verify functionality
- Fix test assertions to match actual response format