Skip to content

Commit

Permalink
add code coverage badge
Browse files Browse the repository at this point in the history
  • Loading branch information
KnicKnic committed Jul 7, 2019
1 parent b6ba7e3 commit 5bad2ef
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 2 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ c/**
**.lib
**.a
host.h
*.ps1
__debug_bin


5 changes: 4 additions & 1 deletion readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
[![Build Status](https://dev.azure.com/oneeyedelf1/powershell.native/_apis/build/status/KnicKnic.go-powershell?branchName=master)](https://dev.azure.com/oneeyedelf1/powershell.native/_build/latest?definitionId=3&branchName=master) [![Go Report Card](https://goreportcard.com/badge/github.com/KnicKnic/go-powershell)](https://goreportcard.com/report/github.com/KnicKnic/go-powershell) [![GoDoc](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell?status.svg)](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell)
[![Build Status](https://dev.azure.com/oneeyedelf1/powershell.native/_apis/build/status/KnicKnic.go-powershell?branchName=master)](https://dev.azure.com/oneeyedelf1/powershell.native/_build/latest?definitionId=3&branchName=master)
[![Go Report Card](https://goreportcard.com/badge/github.com/KnicKnic/go-powershell)](https://goreportcard.com/report/github.com/KnicKnic/go-powershell)
[![gopherbadger](https://img.shields.io/badge/Go%20Coverage-97%25-brightgreen.svg?longCache=true&style=flat)](./scripts/code_coverage.ps1)
[![GoDoc](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell?status.svg)](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell)

# Status
It works
Expand Down
3 changes: 3 additions & 0 deletions scripts/code_coverage.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
go test ./... -coverprofile=coverage; go tool cover -func=coverage; del coverage

#update badge in readme.md with coverage ammount
16 changes: 16 additions & 0 deletions scripts/go_ops.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# run fmt vet and lint

go fmt github.com/KnicKnic/go-powershell/pkg/powershell
go fmt github.com/KnicKnic/go-powershell/pkg/logger
go fmt github.com/KnicKnic/go-powershell/examples/simple
go fmt github.com/KnicKnic/go-powershell/examples/cmd

go vet github.com/KnicKnic/go-powershell/pkg/powershell
go vet github.com/KnicKnic/go-powershell/pkg/logger
go vet github.com/KnicKnic/go-powershell/examples/simple
go vet github.com/KnicKnic/go-powershell/examples/cmd

golint github.com/KnicKnic/go-powershell/pkg/powershell
golint github.com/KnicKnic/go-powershell/pkg/logger
golint github.com/KnicKnic/go-powershell/examples/simple
golint github.com/KnicKnic/go-powershell/examples/cmd

0 comments on commit 5bad2ef

Please sign in to comment.