INNER CODE UNIT · Go
TestAPIGatewayV1Base
akrylysov/algnhsa · apigw_v1_test.go:153
func TestAPIGatewayV1Base(t *testing.T) {
asrt := assert.New(t)
dump, err := dumpAPIGatewayV1([]byte(apiGatewayV1TestEvent), Options{})
asrt.NoError(err)
asrt.Equal(expectedApiGatewayV1Dump, dump)
}
func TestAPIGatewayV1ProxyPath(t *testing.T) {
asrt := assert.New(t)
dump, err := dumpAPIGatewayV1([]byte(apiGatewayV1TestEvent), Options{UseProxyPath: true})
asrt.NoError(err)
expected := expectedApiGatewayV1Dump
expected.RequestURI = "/my/path2?parameter1=value1¶meter1=value2¶meter2=value"
expected.URL.Path = "/my/path2"