Skip to content

Commit f05d97a

Browse files
authored
add github actions (#5)
* add github actions to albatross-client-go * added codecov.yml
1 parent db93ebb commit f05d97a

File tree

5 files changed

+79
-1
lines changed

5 files changed

+79
-1
lines changed

.github/workflows/master.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: master
2+
on:
3+
push:
4+
branches:
5+
- "master"
6+
jobs:
7+
test:
8+
name: test
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v2
12+
- name: setup-go
13+
uses: actions/setup-go@v2
14+
with:
15+
go-version: '^1.14.0'
16+
- name: setup-project
17+
run: make setup
18+
- name: Generate Coverage Report
19+
run: make testcodecov
20+
- name: Upload coverage to Codecov
21+
uses: codecov/codecov-action@v2
22+
with:
23+
files: ./coverage.txt
24+
fail_ci_if_error: true
25+
verbose: true

.github/workflows/pull-request.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: pull-request
2+
on:
3+
pull_request:
4+
jobs:
5+
test:
6+
name: test
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v2
10+
- name: setup-go
11+
uses: actions/setup-go@v2
12+
with:
13+
go-version: '^1.14.0'
14+
- name: setup-project
15+
run: make setup
16+
- name: Generate Coverage Report
17+
run: make testcodecov
18+
- name: Upload coverage to Codecov
19+
uses: codecov/codecov-action@v2
20+
with:
21+
files: ./coverage.txt
22+
fail_ci_if_error: true
23+
verbose: true

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,6 @@
1313

1414
.vscode
1515

16-
golangci-lint
16+
golangci-lint
17+
18+
bin

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
![Build Status](https://github.com/gojekfarm/albatross-client-go/actions/workflows/master.yml/badge.svg?branch=master)
2+
[![codecov](https://codecov.io/gh/gojekfarm/albatross-client-go/branch/master/graph/badge.svg)](https://codecov.io/gh/gojekfarm/albatross-client-go)
3+
4+
15
# Albatross Client Go
26

37
A go client to interact with the albatross API

codecov.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
codecov:
2+
require_ci_to_pass: yes
3+
4+
coverage:
5+
precision: 2
6+
round: down
7+
range: "60...90"
8+
9+
parsers:
10+
gcov:
11+
branch_detection:
12+
conditional: yes
13+
loop: yes
14+
method: no
15+
macro: no
16+
17+
ignore:
18+
- "logger/*"
19+
- "flags/*"
20+
21+
comment:
22+
layout: "reach,diff,flags,files"
23+
behavior: default
24+
require_changes: no

0 commit comments

Comments
 (0)