iris/_examples/mvc/grpc-compatible/main_test.go
Gerasimos (Makis) Maropoulos 5d3c96947c New: gRPC MVC features, new WithLowercaseRouting option and add some new context methods
read HISTORY.md


Former-commit-id: 30a16cceb11f754aa32923058abeda1e736350e7
2020-04-25 02:30:19 +03:00

17 lines
349 B
Go

package main
import (
"testing"
"github.com/kataras/iris/v12/httptest"
)
func TestGRPCCompatible(t *testing.T) {
app := newApp()
e := httptest.New(t, app)
e.POST("/helloworld.Greeter/SayHello").WithJSON(map[string]string{"name": "makis"}).Expect().
Status(httptest.StatusOK).
JSON().Equal(map[string]string{"message": "Hello makis"})
}