-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
41 lines (31 loc) · 994 Bytes
/
Makefile
File metadata and controls
41 lines (31 loc) · 994 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
.PHONY: test test-unit test-integration test-all test-coverage migrate-version migrate-up migrate-down migrate-new migrate-force
# Database migrations
migrate-version:
@./script/migrate.sh version
migrate-up:
@./script/migrate.sh up
migrate-down:
@./script/migrate.sh down
migrate-new:
@./script/migrate.sh new $(name)
migrate-force:
@./script/migrate.sh force $(version)
# Run all Go unit tests
test-unit:
@echo "Running Go unit tests..."
go test ./grpc/services/... ./k8s/tracker/... -v
# Run integration tests (bash scripts)
test-integration:
@echo "Running integration tests..."
./k8s/run-tests.sh
# Run all tests
test-all: test-unit test-integration
# Run tests with coverage
test-coverage:
@echo "Running tests with coverage..."
go test ./grpc/services/... ./k8s/tracker/... -coverprofile=coverage.out
go tool cover -html=coverage.out -o coverage.html
@echo "Coverage report generated: coverage.html"
# Clean test artifacts
clean:
rm -f coverage.out coverage.html