mirror of
https://github.com/aquasecurity/trivy.git
synced 2025-12-12 07:40:48 -08:00
.circleci: Add code coverage (#572)
Signed-off-by: Simarpreet Singh <simar@linux.com>
This commit is contained in:
8
.circleci/codecov.yml
Normal file
8
.circleci/codecov.yml
Normal file
@@ -0,0 +1,8 @@
|
||||
coverage:
|
||||
status:
|
||||
project:
|
||||
default:
|
||||
informational: true
|
||||
patch:
|
||||
default:
|
||||
informational: true
|
||||
@@ -1,4 +1,6 @@
|
||||
version: 2.1
|
||||
orbs:
|
||||
codecov: codecov/codecov@1.1.0
|
||||
|
||||
defaults: &defaults
|
||||
docker :
|
||||
@@ -24,6 +26,9 @@ jobs:
|
||||
- run:
|
||||
name: Test
|
||||
command: make test
|
||||
- codecov/upload:
|
||||
file: ./coverage.txt
|
||||
|
||||
release:
|
||||
<<: *defaults
|
||||
steps:
|
||||
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -18,4 +18,5 @@
|
||||
thumbs.db
|
||||
|
||||
# test fixtures
|
||||
coverage.txt
|
||||
integration/testdata/fixtures/
|
||||
|
||||
2
Makefile
2
Makefile
@@ -28,7 +28,7 @@ $(GOBIN)/golangci-lint:
|
||||
|
||||
.PHONY: test
|
||||
test:
|
||||
go test -v -short ./...
|
||||
go test -v -short -coverprofile=coverage.txt -covermode=atomic ./...
|
||||
|
||||
integration/testdata/fixtures/*.tar.gz:
|
||||
git clone https://github.com/aquasecurity/trivy-test-images.git integration/testdata/fixtures
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
[](https://goreportcard.com/report/github.com/aquasecurity/trivy)
|
||||
[](https://github.com/aquasecurity/trivy/blob/master/LICENSE)
|
||||
[](https://microbadger.com/images/aquasec/trivy "Get your own version badge on microbadger.com")
|
||||
[](https://codecov.io/gh/aquasecurity/trivy)
|
||||
|
||||
A Simple and Comprehensive Vulnerability Scanner for Containers and other Artifacts, Suitable for CI.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user