Skip to content
This repository has been archived by the owner on May 11, 2022. It is now read-only.

Commit

Permalink
issue #26: update scrutinizer config
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilsk committed Apr 28, 2018
1 parent 6c39b43 commit 8336d65
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 30 deletions.
3 changes: 2 additions & 1 deletion .scrutinizer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ build:

tests:
override:
- make test-with-coverage-profile ARGS='-timeout=1s'
- command: make test-with-coverage-profile ARGS='-timeout=1s'
coverage: { file: 'cover.out', format: 'go-cc' }

checks:
go: true
Expand Down
15 changes: 6 additions & 9 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@ language: go
go:
- master
- 1.x
- 1.5.x
- 1.6.x
- 1.7.x
# blocked by issue#39
#- 1.5.x
#- 1.6.x
#- 1.7.x
- 1.8.x
- 1.9.x
- 1.10.x
Expand All @@ -17,17 +18,13 @@ matrix:

sudo: false

before_install:
#- export GO_TEST_COVERAGE_FILENAME='coverage.out'
- export GO15VENDOREXPERIMENT=1

#- go get github.com/mattn/goveralls
#before_install:
#- export GO15VENDOREXPERIMENT=1

script:
- make test-with-coverage-profile ARGS='-timeout=1s'

after_success:
#- goveralls -service=travis-ci -coverprofile="${GO_TEST_COVERAGE_FILENAME}"
- echo $TRAVIS_GO_VERSION ":" $TRAVIS_TAG
- if [[ $TRAVIS_GO_VERSION == 1.10* ]] && [ -n "$TRAVIS_TAG" ]; then curl -sL https://git.io/goreleaser | bash; fi

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ $ check completion zsh > /path/to/zsh-completions/_check.zsh

## Notes

- tested on Go 1.5, 1.6, 1.7, 1.8, 1.9 and 1.10
- tested on Go 1.8, 1.9 and 1.10

---

Expand Down
18 changes: 0 additions & 18 deletions http/availability/crawler_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package availability_test

import (
"html/template"
"io/ioutil"
"sync"
"testing"
Expand All @@ -10,23 +9,6 @@ import (
"github.com/stretchr/testify/assert"
)

var (
html = `
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Links</title>
</head>
<body>
<ul>{{ range . }}
<li><a href="{{ .Href }}">{{ .Text }}</a></li>
{{ end }}</ul>
</body>
`
tpl = template.Must(template.New("links").Parse(html))
)

func TestCrawlerColly(t *testing.T) {
site, closer := site()
defer closer()
Expand Down
18 changes: 18 additions & 0 deletions http/availability/helper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,30 @@ package availability_test

import (
"fmt"
"html/template"
"net/http"
"net/http/httptest"
"strconv"
"strings"
)

var (
html = `
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Links</title>
</head>
<body>
<ul>{{ range . }}
<li><a href="{{ .Href }}">{{ .Text }}</a></li>
{{ end }}</ul>
</body>
`
tpl = template.Must(template.New("links").Parse(html))
)

var echoCode = func(rw http.ResponseWriter, req *http.Request) error {
code, _ := strconv.Atoi(strings.TrimLeft(req.URL.Path, "/"))

Expand Down
2 changes: 1 addition & 1 deletion http/availability/report.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ type event interface {
family()
}

// NewReadableEventBus returns RW channel of events.
// NewReadableEventBus returns rw-channel of events.
func NewReadableEventBus(size int) chan event {
return make(chan event, size)
}
Expand Down

0 comments on commit 8336d65

Please sign in to comment.