Documentation
¶
Index ¶
- func NewClient(serverImpl monorail.MonorailServer) monorail.MonorailClient
- type ServerMock
- func (s *ServerMock) GetIssue(c context.Context, in *monorail.GetIssueRequest) (*monorail.Issue, error)
- func (s *ServerMock) InsertComment(c context.Context, in *monorail.InsertCommentRequest) (*monorail.InsertCommentResponse, error)
- func (s *ServerMock) InsertIssue(c context.Context, in *monorail.InsertIssueRequest) (*monorail.InsertIssueResponse, error)
- func (s *ServerMock) IssuesList(c context.Context, in *monorail.IssuesListRequest) (*monorail.IssuesListResponse, error)
- func (s *ServerMock) ListComments(c context.Context, in *monorail.ListCommentsRequest) (*monorail.ListCommentsResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClient ¶
func NewClient(serverImpl monorail.MonorailServer) monorail.MonorailClient
NewClient creates as client based on a server implementation.
Types ¶
type ServerMock ¶
type ServerMock struct { InsertIssueImpl func(context.Context, *monorail.InsertIssueRequest) (*monorail.InsertIssueResponse, error) InsertCommentImpl func(context.Context, *monorail.InsertCommentRequest) (*monorail.InsertCommentResponse, error) IssuesListImpl func(context.Context, *monorail.IssuesListRequest) (*monorail.IssuesListResponse, error) GetIssueImpl func(context.Context, *monorail.GetIssueRequest) (*monorail.Issue, error) ListCommentsImpl func(context.Context, *monorail.ListCommentsRequest) (*monorail.ListCommentsResponse, error) }
ServerMock delegates method implementations to function pointers. If the function pointer is not initialized, the method panics.
func (*ServerMock) GetIssue ¶
func (s *ServerMock) GetIssue(c context.Context, in *monorail.GetIssueRequest) (*monorail.Issue, error)
GetIssue implements MonorailServer.
func (*ServerMock) InsertComment ¶
func (s *ServerMock) InsertComment(c context.Context, in *monorail.InsertCommentRequest) (*monorail.InsertCommentResponse, error)
InsertComment implements MonorailServer.
func (*ServerMock) InsertIssue ¶
func (s *ServerMock) InsertIssue(c context.Context, in *monorail.InsertIssueRequest) (*monorail.InsertIssueResponse, error)
InsertIssue implements MonorailServer.
func (*ServerMock) IssuesList ¶
func (s *ServerMock) IssuesList(c context.Context, in *monorail.IssuesListRequest) (*monorail.IssuesListResponse, error)
IssuesList implements MonorailServer.
func (*ServerMock) ListComments ¶
func (s *ServerMock) ListComments(c context.Context, in *monorail.ListCommentsRequest) (*monorail.ListCommentsResponse, error)
ListComments implements MonorailServer.
Click to show internal directories.
Click to hide internal directories.