MCPcopy Create free account
hub / github.com/cli/cli / ListLatestSessionsForViewer

Method ListLatestSessionsForViewer

pkg/cmd/agent-task/capi/client_mock.go:370–385  ·  view source on GitHub ↗

ListLatestSessionsForViewer calls ListLatestSessionsForViewerFunc.

(ctx context.Context, limit int)

Source from the content-addressed store, hash-verified

368
369// ListLatestSessionsForViewer calls ListLatestSessionsForViewerFunc.
370func (mock *CapiClientMock) ListLatestSessionsForViewer(ctx context.Context, limit int) ([]*Session, error) {
371 if mock.ListLatestSessionsForViewerFunc == nil {
372 panic("CapiClientMock.ListLatestSessionsForViewerFunc: method is nil but CapiClient.ListLatestSessionsForViewer was just called")
373 }
374 callInfo := struct {
375 Ctx context.Context
376 Limit int
377 }{
378 Ctx: ctx,
379 Limit: limit,
380 }
381 mock.lockListLatestSessionsForViewer.Lock()
382 mock.calls.ListLatestSessionsForViewer = append(mock.calls.ListLatestSessionsForViewer, callInfo)
383 mock.lockListLatestSessionsForViewer.Unlock()
384 return mock.ListLatestSessionsForViewerFunc(ctx, limit)
385}
386
387// ListLatestSessionsForViewerCalls gets all the calls that were made to ListLatestSessionsForViewer.
388// Check the length with:

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected