mirror of
https://github.com/DingTalk-Real-AI/dingtalk-workspace-cli.git
synced 2026-09-28 13:14:08 +08:00
11 lines
249 B
Bash
Executable File
11 lines
249 B
Bash
Executable File
#!/bin/sh
|
|
set -eu
|
|
|
|
ROOT="$(CDPATH= cd -- "$(dirname -- "$0")/../.." && pwd)"
|
|
PROFILE="${1:-$ROOT/coverage.out}"
|
|
|
|
cd "$ROOT"
|
|
go test -coverprofile="$PROFILE" ./...
|
|
go tool cover -func="$PROFILE" | tail -n 1
|
|
printf 'coverage profile: %s\n' "$PROFILE"
|