diff --git a/Dockerfile b/Dockerfile index 905416a9..d8932b93 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,7 +3,7 @@ FROM umputun/baseimage:buildgo-latest as build-backend ADD . /go/src/github.com/umputun/remark WORKDIR /go/src/github.com/umputun/remark -RUN cd app && go test -v $(go list -e ./... | grep -v vendor) +RUN cd app && go test -v -race $(go list -e ./... | grep -v vendor) RUN gometalinter --disable-all --deadline=300s --vendor --enable=vet --enable=vetshadow --enable=golint \ --enable=staticcheck --enable=ineffassign --enable=goconst --enable=errcheck --enable=unconvert \ diff --git a/app/rest/api/rest_test.go b/app/rest/api/rest_test.go index 3c15700f..c432ecce 100644 --- a/app/rest/api/rest_test.go +++ b/app/rest/api/rest_test.go @@ -23,7 +23,7 @@ import ( ) var testDb = "/tmp/test-remark.db" -var testHtml = "/tmp/test-remark.html" +var testHTML = "/tmp/test-remark.html" func TestServer_Ping(t *testing.T) { srv, port := prep(t) @@ -426,7 +426,7 @@ func prep(t *testing.T) (srv *Rest, port int) { WebRoot: "/tmp", } - ioutil.WriteFile(testHtml, []byte("some html"), 0700) + ioutil.WriteFile(testHTML, []byte("some html"), 0700) portSetCh := make(chan bool) go func() { port = rand.Intn(50000) + 1025 @@ -469,7 +469,7 @@ func cleanup(srv *Rest) { srv.httpServer.Close() srv.httpServer.Shutdown(context.Background()) os.Remove(testDb) - os.Remove(testHtml) + os.Remove(testHTML) } type mockCache struct{}