diff --git a/.gitignore b/.gitignore index 63103b08d..80e850b87 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ *.log *.exe cover.out +vendor/ \ No newline at end of file diff --git a/.travis.yml b/.travis.yml index 98c92854b..c2216206a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,15 +12,11 @@ matrix: - go: 1.4 install: - - go get github.com/axw/gocov/gocov - - go get github.com/mattn/goveralls - - go get golang.org/x/tools/cmd/cover - # - go get github.com/golang/lint/golint - - go get github.com/pierrre/gotestcover + - go get github.com/axw/gocov/gocov github.com/mattn/goveralls golang.org/x/tools/cmd/cover github.com/pierrre/gotestcover github.com/Masterminds/glide - go get -t ./... script: - go vet -x $(go list ./... | grep -v /internal/ | grep -v /vendor/) - # - golint . - - gotestcover -coverprofile="cover.out" -race -covermode="count" ./... + - glide install + - gotestcover -coverprofile="cover.out" -race -covermode="count" $(go list ./... | grep -v /vendor/) - goveralls -coverprofile="cover.out" diff --git a/authorize_request_handler_test.go b/authorize_request_handler_test.go index 132424b65..52b90fa58 100644 --- a/authorize_request_handler_test.go +++ b/authorize_request_handler_test.go @@ -10,8 +10,8 @@ import ( . "github.com/ory-am/fosite" . "github.com/ory-am/fosite/internal" "github.com/stretchr/testify/assert" - "github.com/vektra/errors" "golang.org/x/net/context" + "github.com/go-errors/errors" ) // Should pass diff --git a/glide.lock b/glide.lock new file mode 100644 index 000000000..ebff004a9 --- /dev/null +++ b/glide.lock @@ -0,0 +1,74 @@ +hash: 6d94cefa16a96f3c2a7408c2a13982c39a7f04278a5bb10bfc124a51d3274b0c +updated: 2016-05-10T11:17:32.216420413+02:00 +imports: +- name: github.com/asaskevich/govalidator + version: 5b6e9375cbf581a9008064f7216e816b568d6daa +- name: github.com/davecgh/go-spew + version: 5215b55f46b2b919f50a1df0eaa5886afe4e3b3d + subpackages: + - spew +- name: github.com/dgrijalva/jwt-go + version: 40bd0f3b4891a9d7f121bfb7b8e8b0525625e262 +- name: github.com/go-errors/errors + version: a41850380601eeb43f4350f7d17c6bbd8944aaf8 +- name: github.com/golang/mock + version: bd3c8e81be01eef76d4b503f5e687d2d1354d2d9 + subpackages: + - gomock +- name: github.com/golang/protobuf + version: 7cc19b78d562895b13596ddce7aafb59dd789318 + subpackages: + - proto +- name: github.com/moul/http2curl + version: 1812aee76a1ce98d604a44200c6a23c689b17a89 +- name: github.com/oleiade/reflections + version: 632977f98cd34d217c4b57d0840ec188b3d3dcaf +- name: github.com/ory-am/common + version: 930cc805232909c38f2e68310b1e21f71b056d59 + subpackages: + - pkg +- name: github.com/parnurzeal/gorequest + version: a39a2f8d0463091df7344dbf586a9986e9f7184f +- name: github.com/pborman/uuid + version: c55201b036063326c5b1b89ccfe45a184973d073 +- name: github.com/pmezard/go-difflib + version: d8ed2627bdf02c080bf22230dbb337003b7aba2d + subpackages: + - difflib +- name: github.com/Sirupsen/logrus + version: cd7d1bbe41066b6c1f19780f895901052150a575 +- name: github.com/stretchr/testify + version: 6cb3b85ef5a0efef77caef88363ec4d4b5c0976d + subpackages: + - assert + - require +- name: golang.org/x/crypto + version: 91ab96ae987aef3e74ab78b3aaf026109d206148 + subpackages: + - bcrypt + - blowfish +- name: golang.org/x/net + version: 2a35e686583654a1b89ca79c4ac78cb3d6529ca3 + subpackages: + - context + - publicsuffix +- name: golang.org/x/oauth2 + version: e86e2718db89775a4604abc10a5d3a5672e7336e + subpackages: + - clientcredentials + - internal +- name: golang.org/x/sys + version: b776ec39b3e54652e09028aaaaac9757f4f8211a + subpackages: + - unix +- name: google.golang.org/appengine + version: e234e71924d4aa52444bc76f2f831f13fa1eca60 + subpackages: + - urlfetch + - internal + - internal/urlfetch + - internal/base + - internal/datastore + - internal/log + - internal/remote_api +devImports: [] diff --git a/glide.yaml b/glide.yaml new file mode 100644 index 000000000..62e8f77fa --- /dev/null +++ b/glide.yaml @@ -0,0 +1,22 @@ +package: github.com/ory-am/fosite +import: +- package: github.com/asaskevich/govalidator +- package: github.com/dgrijalva/jwt-go +- package: github.com/go-errors/errors +- package: github.com/golang/mock + subpackages: + - gomock +- package: github.com/ory-am/common + subpackages: + - pkg +- package: github.com/parnurzeal/gorequest +- package: github.com/pborman/uuid +- package: golang.org/x/crypto + subpackages: + - bcrypt +- package: golang.org/x/net + subpackages: + - context +- package: golang.org/x/oauth2 + subpackages: + - clientcredentials diff --git a/handler/core/strategy/jwt.go b/handler/core/strategy/jwt.go index c4683555a..f4a5b4424 100644 --- a/handler/core/strategy/jwt.go +++ b/handler/core/strategy/jwt.go @@ -1,11 +1,10 @@ package strategy import ( - "errors" - "github.com/ory-am/fosite" "github.com/ory-am/fosite/token/jwt" "golang.org/x/net/context" + "github.com/go-errors/errors" ) type JWTSessionContainer interface {