From 484f85aacbf55f0696a51347989bd35463d71c11 Mon Sep 17 00:00:00 2001 From: Valery Piashchynski Date: Mon, 2 Nov 2020 12:01:05 +0300 Subject: Add Makefile to run tests with debug tag (to see stacktrace) Remove endure errors and replace it with spiral errors --- Makefile | 2 ++ go.mod | 1 + go.sum | 2 ++ plugins/app/app.go | 5 +++-- plugins/rpc/rpc.go | 2 +- 5 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..ae2adce4 --- /dev/null +++ b/Makefile @@ -0,0 +1,2 @@ +test: + go test -v -race -tags=debug . \ No newline at end of file diff --git a/go.mod b/go.mod index 4fff8f62..3cd3e0ae 100755 --- a/go.mod +++ b/go.mod @@ -11,6 +11,7 @@ require ( github.com/shirou/gopsutil v2.20.9+incompatible github.com/spf13/viper v1.7.1 github.com/spiral/endure v1.0.0-beta10 + github.com/spiral/errors v1.0.0 github.com/spiral/goridge/v2 v2.4.5 github.com/stretchr/testify v1.6.1 github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a diff --git a/go.sum b/go.sum index fef45035..9e37905e 100755 --- a/go.sum +++ b/go.sum @@ -197,6 +197,8 @@ github.com/spf13/viper v1.7.1 h1:pM5oEahlgWv/WnHXpgbKz7iLIxRf65tye2Ci+XFK5sk= github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/spiral/endure v1.0.0-beta10 h1:eAFnJspvmMRDL3u7iwWK8eewogMhq4TTG3CjCBPnbeI= github.com/spiral/endure v1.0.0-beta10/go.mod h1:mXFf8zPqr1SJ1cG0Zf59f6X+MvJzrdIwVjzQpa107e0= +github.com/spiral/errors v1.0.0 h1:wdmJqAFY2Uf8KFK6b8Wkh6vxX++2+GwJWAUplrNTLD0= +github.com/spiral/errors v1.0.0/go.mod h1:SwMSZVdZkkJVgXNNafccqOaxWg0XPzVU/dEdUEInE0o= github.com/spiral/goridge/v2 v2.4.5 h1:rg4lLEJLrEh1Wj6G1qTsYVbYiQvig6mOR1F9GyDIGm8= github.com/spiral/goridge/v2 v2.4.5/go.mod h1:C/EZKFPON9lypi8QO7I5ObgVmrIzTmhZqFz/tmypcGc= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= diff --git a/plugins/app/app.go b/plugins/app/app.go index 9301e38f..312e5bc6 100644 --- a/plugins/app/app.go +++ b/plugins/app/app.go @@ -3,12 +3,13 @@ package app import ( "context" "fmt" - "go.uber.org/zap" "os" "os/exec" "strings" - "github.com/spiral/endure/errors" + "go.uber.org/zap" + + "github.com/spiral/errors" "github.com/spiral/roadrunner/v2" "github.com/spiral/roadrunner/v2/plugins/config" "github.com/spiral/roadrunner/v2/util" diff --git a/plugins/rpc/rpc.go b/plugins/rpc/rpc.go index d272fc72..f299bd55 100755 --- a/plugins/rpc/rpc.go +++ b/plugins/rpc/rpc.go @@ -6,7 +6,7 @@ import ( "go.uber.org/zap" "github.com/spiral/endure" - "github.com/spiral/endure/errors" + "github.com/spiral/errors" "github.com/spiral/goridge/v2" "github.com/spiral/roadrunner/v2/plugins/config" ) -- cgit v1.2.3 From ba39499332aee7af9d237774a2b9e786a04f7736 Mon Sep 17 00:00:00 2001 From: Valery Piashchynski Date: Mon, 2 Nov 2020 12:05:00 +0300 Subject: Add newline to the end of the Makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index ae2adce4..128e2a5a 100644 --- a/Makefile +++ b/Makefile @@ -1,2 +1,2 @@ test: - go test -v -race -tags=debug . \ No newline at end of file + go test -v -race -tags=debug . -- cgit v1.2.3