From 404406b821351feb3bfdc7adb6476bc359e6b0dd Mon Sep 17 00:00:00 2001 From: Mike Arpaia Date: Mon, 8 Aug 2016 09:50:54 -0700 Subject: [PATCH] TravisCI configurations (#46) --- .travis.yml | 9 +++++++++ Godeps/Godeps.json | 30 ++++++++---------------------- README.md | 2 +- sessions/sessions_test.go | 2 +- users.go | 2 +- 5 files changed, 20 insertions(+), 25 deletions(-) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000000..3fb40f1f46 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,9 @@ +language: go + +go: + - 1.6.3 + - tip + +script: + - go test -v ./... + - go vet ./... \ No newline at end of file diff --git a/Godeps/Godeps.json b/Godeps/Godeps.json index 7f02a5cd7d..f636b9b46c 100644 --- a/Godeps/Godeps.json +++ b/Godeps/Godeps.json @@ -22,8 +22,8 @@ }, { "ImportPath": "github.com/dgrijalva/jwt-go", - "Comment": "v3.0.0-6-g63734ea", - "Rev": "63734eae1ef55eaac06fdc0f312615f2e321e273" + "Comment": "v3.0.0-4-g01aeca5", + "Rev": "01aeca54ebda6e0fbfafd0a524d234159c05ec20" }, { "ImportPath": "github.com/gin-gonic/contrib/ginrus", @@ -46,26 +46,12 @@ }, { "ImportPath": "github.com/go-sql-driver/mysql", - "Comment": "v1.2-198-g0b58b37", - "Rev": "0b58b37b664c21f3010e836f1b931e1d0b0b0685" + "Comment": "v1.2-196-g3654d25", + "Rev": "3654d25ec346ee8ce71a68431025458d52a38ac0" }, { "ImportPath": "github.com/golang/protobuf/proto", - "Rev": "c3cefd437628a0b7d31b34fe44b3a7a540e98527" - }, - { - "ImportPath": "github.com/gorilla/context", - "Comment": "v1.1-4-gaed02d1", - "Rev": "aed02d124ae4a0e94fea4541c8effd05bf0c8296" - }, - { - "ImportPath": "github.com/gorilla/securecookie", - "Comment": "v1.1-2-gff35634", - "Rev": "ff356348f74133a59d3e93aa24b5b4551b6fe90d" - }, - { - "ImportPath": "github.com/gorilla/sessions", - "Rev": "56ba4b0a11da87516629a57408a5f7e4c8ea7b0b" + "Rev": "874264fbbb43f4d91e999fecb4b40143ed611400" }, { "ImportPath": "github.com/jinzhu/gorm", @@ -105,7 +91,7 @@ }, { "ImportPath": "golang.org/x/net/context", - "Rev": "f6d211983832e1efcd77e80779fd5f1142741356" + "Rev": "4d38db76854b199960801a1734443fd02870d7e1" }, { "ImportPath": "golang.org/x/sys/unix", @@ -113,8 +99,8 @@ }, { "ImportPath": "gopkg.in/alecthomas/kingpin.v2", - "Comment": "v2.2.2", - "Rev": "e5900212cbf65b181d3d8e08308ef06a01d117cf" + "Comment": "v2.2.0", + "Rev": "92b2733684bc5f1971162349ce098fe0d070e2a9" }, { "ImportPath": "gopkg.in/go-playground/validator.v8", diff --git a/README.md b/README.md index 06278d44b0..0cc10294c1 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Kolide -[![Build Status](https://drone.io/github.com/kolide/kolide-ose/status.png)](https://drone.io/github.com/kolide/kolide-ose/latest) +[![Build Status](https://travis-ci.com/kolide/kolide-ose.svg?token=MvaZkzWisgsA98PZfNC7&branch=master)](https://travis-ci.com/kolide/kolide-ose) ## Building diff --git a/sessions/sessions_test.go b/sessions/sessions_test.go index 796ecb6f1b..12a113b95d 100644 --- a/sessions/sessions_test.go +++ b/sessions/sessions_test.go @@ -60,7 +60,7 @@ func TestSessionManager(t *testing.T) { } if session.UserID != 1 { - t.Fatal("User ID doesn't match. Got: %s", session.UserID) + t.Fatalf("User ID doesn't match. Got: %d", session.UserID) } } diff --git a/users.go b/users.go index 24b82a91d4..96fc50208b 100644 --- a/users.go +++ b/users.go @@ -462,7 +462,7 @@ func SetUserEnabledState(c *gin.Context) { // Setting the session backend via a middleware func SessionBackendMiddleware(c *gin.Context) { db := GetDB(c) - c.Set("SessionBackend", &sessions.GormSessionBackend{db}) + c.Set("SessionBackend", &sessions.GormSessionBackend{DB: db}) c.Next() }