github.com/lbryio/lbcd@v0.22.119/addrmgr/cov_report.sh (about)

     1  #!/bin/sh
     2  
     3  # This script uses gocov to generate a test coverage report.
     4  # The gocov tool my be obtained with the following command:
     5  #   go get github.com/axw/gocov/gocov
     6  #
     7  # It will be installed to $GOPATH/bin, so ensure that location is in your $PATH.
     8  
     9  # Check for gocov.
    10  type gocov >/dev/null 2>&1
    11  if [ $? -ne 0 ]; then
    12  	echo >&2 "This script requires the gocov tool."
    13  	echo >&2 "You may obtain it with the following command:"
    14  	echo >&2 "go get github.com/axw/gocov/gocov"
    15  	exit 1
    16  fi
    17  gocov test | gocov report