mirror of
https://github.com/go-gitea/gitea
synced 2025-09-28 03:28:13 +00:00
test(ping): add testing for gRPC
This commit is contained in:
20
routers/api/bots/ping/ping_test.go
Normal file
20
routers/api/bots/ping/ping_test.go
Normal file
@@ -0,0 +1,20 @@
|
||||
// Copyright 2022 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package ping
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
"testing"
|
||||
|
||||
"gitea.com/gitea/proto-go/ping/v1/pingv1connect"
|
||||
)
|
||||
|
||||
func TestService(t *testing.T) {
|
||||
mux := http.NewServeMux()
|
||||
mux.Handle(pingv1connect.NewPingServiceHandler(
|
||||
&Service{},
|
||||
))
|
||||
MainServiceTest(t, mux)
|
||||
}
|
Reference in New Issue
Block a user