Skip to content

Commit 5c4925e

Browse files
committed
build(tok): add test-new and cover-new Makefile targets for Round 2 packages
Add convenience targets for faster iteration on the packages ported in this session: make test-new — runs only the new packages with -race (3-6s) make cover-new — shows coverage for new packages only Packages covered: internal/compress, internal/extract, internal/tracking Usage: make test-new # fast local iteration on new code make cover-new # check coverage on new code before pushing make test-race # full test suite (CI-recommended)
1 parent 343d9f4 commit 5c4925e

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

Makefile

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ GOVULNCHECK := $(GOBIN_DIR)/govulncheck
2727
# ---------------------------------------------------------------------------
2828
# Phony declarations (alphabetical).
2929
# ---------------------------------------------------------------------------
30-
.PHONY: all bench build ci clean cover fmt help lint lint-fix \
31-
security test test-10x test-race tidy version vet
30+
.PHONY: all bench build ci clean cover cover-new fmt help lint lint-fix \
31+
security test test-10x test-new test-race tidy version vet
3232

3333
# ---------------------------------------------------------------------------
3434
# Default target.
@@ -53,12 +53,18 @@ test-race: ## Run unit tests with the race detector.
5353
test-10x: ## Run tests 10 times to surface flakes.
5454
go test ./... -race -count=10 -timeout=600s
5555

56+
test-new: ## Run only the Round 2 rtk/caveman ported packages (fast iteration).
57+
go test -race -count=1 -timeout=60s ./internal/compress/... ./internal/extract/... ./internal/tracking/...
58+
5659
cover: ## Generate a coverage report (coverage.out + coverage.html).
5760
go test ./... -race -coverprofile=coverage.out -covermode=atomic -timeout=180s
5861
@go tool cover -func=coverage.out | grep "^total:"
5962
@go tool cover -html=coverage.out -o coverage.html
6063
@echo "Coverage report: coverage.html"
6164

65+
cover-new: ## Coverage report for Round 2 rtk/caveman ported packages only.
66+
go test -cover -timeout=30s ./internal/compress/... ./internal/extract/... ./internal/tracking/...
67+
6268
bench: ## Run benchmarks.
6369
go test ./... -bench=. -benchmem -count=3 -timeout=300s
6470

0 commit comments

Comments
 (0)