iris/_examples/mvc/grpc-compatible/main_test.go
Gerasimos (Makis) Maropoulos 6add1ba49b
fix #2158 and more
2023-07-08 02:08:18 +03:00

17 lines
351 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().IsEqual(map[string]string{"message": "Hello makis"})
}