summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWolfy-J <[email protected]>2018-09-21 16:29:34 +0300
committerWolfy-J <[email protected]>2018-09-21 16:29:34 +0300
commitbdff4b25d2a879357bc0ed53e96c0b551de07f88 (patch)
treef624152305e2e6f5d088c0880f67bc11abcaa9b0
parent0f8b7d823f7cfbbc8b47ba1f1562d6112e57a0be (diff)
version bump + fmtv1.2.1
-rw-r--r--cmd/rr/cmd/version.go4
-rw-r--r--service/http/handler_test.go7
2 files changed, 4 insertions, 7 deletions
diff --git a/cmd/rr/cmd/version.go b/cmd/rr/cmd/version.go
index 26744922..a550c682 100644
--- a/cmd/rr/cmd/version.go
+++ b/cmd/rr/cmd/version.go
@@ -1,11 +1,9 @@
package cmd
-import "time"
-
var (
// Version - defines build version.
Version = "local"
// BuildTime - defined build time.
- BuildTime = time.Now().Format(time.RFC1123)
+ BuildTime = "development"
)
diff --git a/service/http/handler_test.go b/service/http/handler_test.go
index b82fc938..3b51c873 100644
--- a/service/http/handler_test.go
+++ b/service/http/handler_test.go
@@ -8,13 +8,13 @@ import (
"io/ioutil"
"mime/multipart"
"net/http"
+ "net/http/httptest"
"net/url"
"os"
"runtime"
"strings"
"testing"
"time"
- "net/http/httptest"
)
// get request and return body
@@ -113,14 +113,13 @@ func Test_Handler_JSON_error(t *testing.T) {
wr := httptest.NewRecorder()
rq := httptest.NewRequest("POST", "/", bytes.NewBuffer([]byte("{sd")))
- rq.Header.Add("Content-Type","application/json")
- rq.Header.Add("Content-Size","3")
+ rq.Header.Add("Content-Type", "application/json")
+ rq.Header.Add("Content-Size", "3")
st.ServeHTTP(wr, rq)
assert.Equal(t, 500, wr.Code)
}
-
func TestServer_Headers(t *testing.T) {
st := &Handler{
cfg: &Config{