test(auth): add redis and database failure tests

This commit is contained in:
kk10
2026-10-07 17:07:05 +03:00
parent d7002b4dfe
commit fff2cb5b37
2 changed files with 97 additions and 2 deletions
+8 -2
View File
@@ -2,10 +2,13 @@ LOAD_ARGS = $(if $(LOAD_WORKERS),-workers=$(LOAD_WORKERS),) \
$(if $(LOAD_DURATION),-duration=$(LOAD_DURATION),) \
$(if $(LOAD_RATE),-rate=$(LOAD_RATE),)
.PHONY: help-go contract-go race-go load-go
.PHONY: help-go contract-go race-go load-go failure-go
help-go:
@echo "contract-go: student contract tests; race-go: concurrency test with -race; load-go: Go load test"
@echo "contract-go: contract tests"
@echo "race-go: concurrency tests (-race)"
@echo "load-go: load test"
@echo "failure-go: dependency failure tests (stops redis/postgres containers)"
contract-go:
go test -tags=contract ./student-tests/... -v -args -base-url=$(BASE_URL)
@@ -15,3 +18,6 @@ race-go:
load-go:
go test -tags=load ./student-tests/... -v -args -base-url=$(BASE_URL) $(LOAD_ARGS)
failure-go:
go test -tags=failure ./student-tests/... -v -args -base-url=$(BASE_URL)