style(internal/*): fix lint issues

This commit is contained in:
Nightapes
2019-07-21 15:15:01 +02:00
parent 409b260eb7
commit 58f2ebb6d0
2 changed files with 5 additions and 6 deletions

View File

@@ -25,7 +25,8 @@ func TestReadCacheInvalidContent(t *testing.T) {
completePath := path.Join(path.Dir(dir), ".version") completePath := path.Join(path.Dir(dir), ".version")
brokenContent := []byte("hello broken\ngo: lang\n") brokenContent := []byte("hello broken\ngo: lang\n")
ioutil.WriteFile(completePath, brokenContent, 0644) err = ioutil.WriteFile(completePath, brokenContent, 0644)
assert.NoError(t, err)
_, readError := cache.Read(dir) _, readError := cache.Read(dir)
assert.Errorf(t, readError, "Should give error, when broken content") assert.Errorf(t, readError, "Should give error, when broken content")

View File

@@ -1,7 +1,6 @@
package ci_test package ci_test
import ( import (
"fmt"
"testing" "testing"
"time" "time"
@@ -27,10 +26,8 @@ func TestCi(t *testing.T) {
w, err := repository.Worktree() w, err := repository.Worktree()
assert.NoError(t, err, "should get worktree") assert.NoError(t, err, "should get worktree")
w.Add(file.Name()) _, err = w.Add(file.Name())
assert.NoError(t, err, "should add file")
status, err := w.Status()
fmt.Println(status)
gitUtilInMemory := &gitutil.GitUtil{ gitUtilInMemory := &gitutil.GitUtil{
Repository: repository, Repository: repository,
@@ -43,6 +40,7 @@ func TestCi(t *testing.T) {
When: time.Now(), When: time.Now(),
}, },
}) })
assert.NoError(t, err, "should commit")
testConfigs := []struct { testConfigs := []struct {
service string service string