The default test suite uses in-process smart HTTP servers and does not require a local listener:
env GOCACHE=/tmp/go-build go test ./...Optional end-to-end write test against the system git-http-backend:
env GOCACHE=/tmp/go-build GITSYNC_E2E_GIT_HTTP_BACKEND=1 go test ./internal/syncer -run TestRun_GitHTTPBackendSync -vThat path exercises real smart HTTP fetch and push with a local bare source repo and a local bare target repo.
Dedicated batched bootstrap coverage:
env GOCACHE=/tmp/go-build GITSYNC_E2E_GIT_HTTP_BACKEND=1 go test ./internal/syncer -run TestBootstrap_GitHTTPBackendBatchedBranch -vBatch-planning sensitivity coverage:
env GOCACHE=/tmp/go-build GITSYNC_E2E_GIT_HTTP_BACKEND=1 go test ./internal/syncer -run TestBootstrap_GitHTTPBackendBatchedPlanningTracksBatchLimit -vThat test uses a real git-http-backend source/target pair and checks that a smaller --target-max-pack-bytes planning limit produces at least as many planned checkpoints as a larger one, while still planning to the branch tip.
Optional live Linux bootstrap smoke:
env GOCACHE=/tmp/go-build GITSYNC_E2E_LIVE_LINUX=1 go test ./internal/syncer -run TestBootstrap_LiveLinuxSource -vBatched variant:
env GOCACHE=/tmp/go-build GITSYNC_E2E_LIVE_LINUX=1 go test ./internal/syncer -run TestBootstrap_LiveLinuxSourceBatched -vThese are useful for large-source relay and memory checks while keeping the target local and disposable.
git-sync-bench runs repeatable empty-target benchmarks against a source repository. It creates a fresh bare target for each run and reports wall-clock time plus internal syncer measurement data.
Build it with:
go build -o /tmp/git-sync-bench ./cmd/git-sync-benchExample against a local mirror:
/tmp/git-sync-bench \
--scenario bootstrap \
--source-url /tmp/git-sync-bench/kubernetes.git \
--repeat 3 \
--target-max-pack-bytes 104857600 \
--stats \
--jsonThe JSON report includes per-run results, aggregate min/avg/max timings, batch counts for batched runs, heap peaks, and relay modes seen across successful runs. If --source-url is a filesystem path, the tool converts it to file://... automatically.
Use --keep-targets to retain generated bare targets under --work-dir for inspection. For large real-repo runs, prefer a local mirror instead of benchmarking directly against a hosted remote.
mise run test— default suitemise run test:ci— default suite with race detectionmise run test:git-http-backend—git-http-backendend-to-endmise run test:linux-smoke— live Linux bootstrap smokemise run test:linux-smoke:batched— live Linux batched bootstrap smoke
test:linux-smoke and test:linux-smoke:batched use a disposable local bare Git target served through git-http-backend. They do not require any external service beyond the public source remote.
For local or self-signed targets:
--source-insecure-skip-tls-verify--target-insecure-skip-tls-verifyGITSYNC_SOURCE_INSECURE_SKIP_TLS_VERIFY=trueGITSYNC_TARGET_INSECURE_SKIP_TLS_VERIFY=true