refactor: add test-with-server targets to all S3 test directories

- Add test-with-server target to acl, basic, delete, etag Makefiles
- Simplify test-with-server to use TestMain-based server auto-management
- Update tagging, cors, filer_group, retention, remote_cache, sse Makefiles
- Add TEST_PATTERN support for CI/CD parameterized testing
- Remove complex manual server management from test-with-server
- All targets now delegate to TestMain for consistent, simplified server lifecycle
- Backward compatible with existing make targets for manual testing
This commit is contained in:
Chris Lu
2025-12-24 19:30:57 -08:00
parent 40f30e6629
commit ee0e08a32d
13 changed files with 186 additions and 66 deletions
+4 -8
View File
@@ -169,14 +169,10 @@ test: check-deps
@go test -v -timeout=$(TEST_TIMEOUT) -run "$(TEST_PATTERN)" .
@echo "Tests completed"
# Full test workflow
test-with-server: start-remote start-primary
@sleep 3
@$(MAKE) setup-remote || (echo "Remote setup failed" && $(MAKE) stop-primary stop-remote && exit 1)
@sleep 2
@echo "Running remote cache tests..."
@$(MAKE) test || (echo "Tests failed" && tail -50 primary-weed.log && $(MAKE) stop-primary stop-remote && exit 1)
@$(MAKE) stop-primary stop-remote
# Full test workflow - use auto-managed server via TestMain
test-with-server: check-deps
@echo "Running remote cache tests with auto-managed servers..."
@go test -v -timeout=$(TEST_TIMEOUT) ./...
@echo "All tests passed"
# Show logs