mirror of
https://github.com/runkids/skillshare.git
synced 2026-11-20 20:34:19 +00:00
Add complete integration test coverage for all CLI commands with isolated sandbox environments that run on every change. Changes: - Add testutil package for sandbox test infrastructure - Add 77 integration tests covering all commands (init, sync, status, diff, backup, restore, pull, doctor, target, version, help) - Update CI workflow to run integration tests on Ubuntu and macOS - Add SKILLSHARE_CONFIG env var support for test isolation - Add mise.toml for task management - Move scripts to scripts/ directory
42 lines
998 B
TOML
42 lines
998 B
TOML
[tools]
|
|
go = "1.23"
|
|
|
|
[tasks.build]
|
|
description = "Build the skillshare binary"
|
|
run = "mkdir -p bin && go build -o bin/skillshare ./cmd/skillshare"
|
|
|
|
[tasks.test]
|
|
description = "Run all tests"
|
|
depends = ["build"]
|
|
run = "SKILLSHARE_TEST_BINARY=$(pwd)/bin/skillshare go test -v ./..."
|
|
|
|
[tasks."test:unit"]
|
|
description = "Run unit tests only"
|
|
run = "go test -v ./internal/..."
|
|
|
|
[tasks."test:int"]
|
|
description = "Run integration tests only"
|
|
depends = ["build"]
|
|
run = "SKILLSHARE_TEST_BINARY=$(pwd)/bin/skillshare go test -v ./tests/integration/..."
|
|
|
|
[tasks."test:cover"]
|
|
description = "Run tests with coverage"
|
|
depends = ["build"]
|
|
run = "SKILLSHARE_TEST_BINARY=$(pwd)/bin/skillshare go test -cover ./..."
|
|
|
|
[tasks.clean]
|
|
description = "Clean build artifacts"
|
|
run = "rm -rf bin/"
|
|
|
|
[tasks.lint]
|
|
description = "Run linter"
|
|
run = "go vet ./..."
|
|
|
|
[tasks.fmt]
|
|
description = "Format code"
|
|
run = "go fmt ./..."
|
|
|
|
[tasks.install]
|
|
description = "Install skillshare to GOPATH/bin"
|
|
run = "go install ./cmd/skillshare"
|