File: test_with_codecoverage.sh

package info (click to toggle)
golang-github-gomarkdown-markdown 0.0~git20231115.a660076-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 1,168 kB
  • sloc: sh: 26; makefile: 5
file content (14 lines) | stat: -rwxr-xr-x 419 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/usr/bin/env bash

# This requires 1.10+ to support -coverprofile with -coverpkg

set -e

# List of packages to test
pkgs=$(go list ./... | grep -v /cmd | grep -v /examples)
# list of packages in a format suitable for -coverpkg
cover_pkgs=$(go list ./... | grep -v /cmd | tr "\n" ",")

go test -race -covermode=atomic -coverprofile=coverage.txt -coverpkg ${cover_pkgs} ${pkgs}

bash <(curl -s https://codecov.io/bash)