Codebase list golang-github-go-kit-kit / f748229
Minor change to coverage.bash script Peter Bourgon 8 years ago
1 changed file(s) with 4 addition(s) and 4 deletion(s). Raw diff Collapse all Expand all
00 #!/usr/bin/env bash
11
2 # This script runs the cover tool on all packages with test files. If you set
3 # an "HTML" environment variable, it will additionally open the web-based
4 # coverage visualizer for each package.
2 # This script runs the cover tool on all packages with test files. If you set a
3 # WEB environment variable, it will additionally open the web-based coverage
4 # visualizer for each package.
55
66 function go_files { find . -name '*_test.go' ; }
77 function filter { grep -v '/_' ; }
2929 package_names | while read pkg
3030 do
3131 go test -coverprofile=cover.out $pkg
32 if [ -n "${HTML+x}" ]
32 if [ -n "${WEB+x}" ]
3333 then
3434 go tool cover -html=cover.out
3535 fi