Agent skill
uv-tdd
A development process for Python code that uses Test Drivern Development (TDD) to iterate on a new project based around uv. Use when creating a new Python project, writing Python code with tests, or working on Python development using test-driven development practices with the uv package manager.
Install this agent skill to your Project
npx add-skill https://github.com/gali-leilei/agent-skills-md/tree/main/skills/uv-tdd
SKILL.md
uv-tdd skill
A development process for Python applications that uses TDD to iterate on a new project based around uv.
Create a project with this command:
mkdir name-of-project
cd name-of-project
uv init --python 3.14
git init (if not already in a git repo)
This creates an initial pyproject.toml file
Add dependencies using:
uv add httpx
Always start by adding a dev dependency of pytest like this:
uv add pytest --dev
Then add a starting test:
mkdir tests
echo 'def test_add():
assert 1 + 1 == 2' > tests/test_add.py
Then run the tests like this:
uv run pytest
Always run Python code like this:
uv run python -c "..."
Always create a README.md for the project, which starts with just the project name as a heading plus a short description.
Start by creating a spec.md file with a detailed specification that includes markdown TODO lists. Update the spec and those TODOs as you progress, including adding new ones and checking off previous ones.
Practice TDD. For every change start by writing a test (grouped sensible in test files with other related tests) and then use uv run pytest -k name_of_test to watch it fail. Then implement the change and watch the test pass. Update the TODOs and add or update relevant documentation in the README, then commit the implementation and tests and documentation as a single commit.
Use and reuse pytest fixtures where appropriate, including for temporary files used for the duration of the test run. Use pytest.mark.parameterized to avoid duplicated test code.
Delete that test_add.py file once you have implemented your first real test. Do not include that test_add.py file in any of your commits.
Commit often, in sensible chunks. If a remote is configured then push after every commit.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
write-python
Write idiomatic and modern (3.14+) python code. Use when writing Python code, CLI tools, scripts, or services. Emphasizes stdlib, type hints, uv/ruff toolchain, and minimal dependencies.
handoff
Compact the current conversation into a handoff document for another agent to pick up.
obsidian-vault
Search, create, and manage notes in the Obsidian vault with wikilinks and index notes. Use when user wants to find, create, or organize notes in Obsidian.
edit-article
Edit and improve articles by restructuring sections, improving clarity, and tightening prose. Use when user wants to edit, revise, or improve an article draft.
scaffold-exercises
Create exercise directory structures with sections, problems, solutions, and explainers that pass linting. Use when user wants to scaffold exercises, create exercise stubs, or set up a new course section.
setup-pre-commit
Set up Husky pre-commit hooks with lint-staged (Prettier), type checking, and tests in the current repo. Use when user wants to add pre-commit hooks, set up Husky, configure lint-staged, or add commit-time formatting/typechecking/testing.
Didn't find tool you were looking for?