Skip to content

Commit d0b4bc3

Browse files
Add make test-concise for AI-friendly test output (#227)
Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com> Co-authored-by: William Easton <[email protected]>
1 parent fefc363 commit d0b4bc3

File tree

2 files changed

+38
-4
lines changed

2 files changed

+38
-4
lines changed

AGENTS.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ make precommit
2323
### Testing Requirements
2424

2525
- All new features require tests in both async and sync packages
26-
- Run `make test` to execute all test suites
26+
- Run `make test` to execute all test suites (verbose output)
27+
- Run `make test-concise` for minimal output (recommended for AI agents)
2728
- Run `make test-aio` for async package tests only
2829
- Run `make test-sync` for sync package tests only
2930
- Test coverage should be maintained
@@ -253,10 +254,14 @@ type annotation issues to maintain type safety guarantees.
253254
| `make install` | Alias for `make sync` |
254255
| `make lint` | Lint Python + Markdown |
255256
| `make typecheck` | Run Basedpyright type checking |
256-
| `make test` | Run all test suites |
257+
| `make test` | Run all test suites (verbose) |
258+
| `make test-concise` | Run all test suites (concise output for AI) |
257259
| `make test-aio` | Run async package tests |
260+
| `make test-aio-concise` | Run async package tests (concise) |
258261
| `make test-sync` | Run sync package tests |
262+
| `make test-sync-concise` | Run sync package tests (concise) |
259263
| `make test-shared` | Run shared package tests |
264+
| `make test-shared-concise` | Run shared package tests (concise) |
260265
| `make codegen` | Generate sync library from async |
261266
| `make precommit` | Run lint + typecheck + codegen |
262267
| `make build` | Build all packages |

Makefile

Lines changed: 31 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.PHONY: bump-version bump-version-dry codegen lint typecheck sync precommit test build help
2-
.PHONY: install test-aio test-sync test-shared docs-serve docs-build docs-deploy
2+
.PHONY: install test-aio test-sync test-shared test-concise test-aio-concise test-sync-concise test-shared-concise docs-serve docs-build docs-deploy
33

44
# Default target - show help
55
.DEFAULT_GOAL := help
@@ -12,10 +12,14 @@ help:
1212
@echo " make install - Alias for sync"
1313
@echo " make lint - Run linters (Python + Markdown)"
1414
@echo " make typecheck - Run type checking"
15-
@echo " make test - Run all tests"
15+
@echo " make test - Run all tests (verbose)"
16+
@echo " make test-concise - Run all tests (concise output for AI agents)"
1617
@echo " make test-aio - Run async package tests"
18+
@echo " make test-aio-concise - Run async package tests (concise)"
1719
@echo " make test-sync - Run sync package tests"
20+
@echo " make test-sync-concise - Run sync package tests (concise)"
1821
@echo " make test-shared - Run shared package tests"
22+
@echo " make test-shared-concise - Run shared package tests (concise)"
1923
@echo " make build - Build all packages"
2024
@echo " make codegen - Generate sync package from async"
2125
@echo " make precommit - Run pre-commit checks (lint + typecheck + codegen)"
@@ -110,6 +114,31 @@ test-shared:
110114
@echo "Testing key-value-shared..."
111115
@uv run pytest key-value/key-value-shared/tests -vv
112116

117+
# Concise test output for AI agents - supports PROJECT parameter
118+
test-concise:
119+
ifdef PROJECT
120+
@echo "Testing $(PROJECT) (concise output)..."
121+
@cd $(PROJECT) && uv run pytest tests . -qq --tb=line --no-header
122+
else
123+
@echo "Testing all packages (concise output)..."
124+
@uv run pytest key-value/key-value-aio/tests -qq --tb=line --no-header
125+
@uv run pytest key-value/key-value-sync/tests -qq --tb=line --no-header
126+
@uv run pytest key-value/key-value-shared/tests -qq --tb=line --no-header
127+
endif
128+
129+
# Convenience targets for specific packages with concise output
130+
test-aio-concise:
131+
@echo "Testing key-value-aio (concise output)..."
132+
@uv run pytest key-value/key-value-aio/tests -qq --tb=line --no-header
133+
134+
test-sync-concise:
135+
@echo "Testing key-value-sync (concise output)..."
136+
@uv run pytest key-value/key-value-sync/tests -qq --tb=line --no-header
137+
138+
test-shared-concise:
139+
@echo "Testing key-value-shared (concise output)..."
140+
@uv run pytest key-value/key-value-shared/tests -qq --tb=line --no-header
141+
113142
# Build target - supports PROJECT parameter
114143
build:
115144
ifdef PROJECT

0 commit comments

Comments
 (0)