Skip to content

Commit

Permalink
1. Changes to .codecov.yml to enable code coverage reports
Browse files Browse the repository at this point in the history
2. Changes to generate-coverage.sh for fixing errors

Fixes redhat-developer#1557
  • Loading branch information
kanchwala-yusuf committed Nov 29, 2019
1 parent 962d052 commit fb11983
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 4 deletions.
29 changes: 27 additions & 2 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,35 @@
codecov:
require_ci_to_pass: no

comment:
behavior: default


coverage:
status:
project:
default: off
# basic
target: auto
threshold: null
base: auto
# advanced
branches: null
if_no_uploads: error
if_not_found: success
if_ci_failed: error
only_pulls: false
flags: null
paths: null
patch:
default: off
# basic
target: auto
threshold: null
base: auto
# advanced
branches: null
if_no_uploads: error
if_not_found: success
if_ci_failed: error
only_pulls: false
flags: null
paths: null
4 changes: 2 additions & 2 deletions scripts/generate-coverage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

set -e
echo "" > coverage.txt
go test -i -race ./cmd/odo
#go test -i -race ./cmd/odo
for d in $(go list ./... | grep -v vendor | grep -v tests | grep -v testingutil); do
# For watch related tests, race check causes issue so disabling them here as race is already tested in other tests when used with `-coverprofile=profile.out`
if [ "$d" = "github.com/openshift/odo/pkg/component" ]; then
Expand All @@ -17,4 +17,4 @@ for d in $(go list ./... | grep -v vendor | grep -v tests | grep -v testingutil)
cat profile.out >> coverage.txt
rm profile.out
fi
done
done

0 comments on commit fb11983

Please sign in to comment.