v0.19.0 55a688e

BrowseService.go RawHistoryFolder

1// Code generated by mockery; DO NOT EDIT.
2// github.com/vektra/mockery
3// template: testify
4
5package mocks
6
7import (
8	"context"
9	"io"
10
11	"bnema.dev/ermite/internal/domain"
12	"bnema.dev/ermite/internal/ports"
13	mock "github.com/stretchr/testify/mock"
14)
15
16// NewBrowseService creates a new instance of BrowseService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
17// The first argument is typically a *testing.T value.
18func NewBrowseService(t interface {
19	mock.TestingT
20	Cleanup(func())
21}) *BrowseService {
22	if helper, ok := t.(interface{ Helper() }); ok {
23		helper.Helper()
24	}
25
26	mock := &BrowseService{}
27	mock.Mock.Test(t)
28
29	t.Cleanup(func() {
30		if helper, ok := t.(interface{ Helper() }); ok {
31			helper.Helper()
32		}
33		mock.AssertExpectations(t)
34	})
35
36	return mock
37}
38
39// BrowseService is an autogenerated mock type for the BrowseService type
40type BrowseService struct {
41	mock.Mock
42}
43
44type BrowseService_Expecter struct {
45	mock *mock.Mock
46}
47
48func (_m *BrowseService) EXPECT() *BrowseService_Expecter {
49	return &BrowseService_Expecter{mock: &_m.Mock}
50}
51
52// GetCommit provides a mock function for the type BrowseService
53func (_mock *BrowseService) GetCommit(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision) (domain.CommitDetail, error) {
54	ret := _mock.Called(ctx, p, repo, rev)
55
56	if len(ret) == 0 {
57		panic("no return value specified for GetCommit")
58	}
59
60	var r0 domain.CommitDetail
61	var r1 error
62	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) (domain.CommitDetail, error)); ok {
63		return returnFunc(ctx, p, repo, rev)
64	}
65	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) domain.CommitDetail); ok {
66		r0 = returnFunc(ctx, p, repo, rev)
67	} else {
68		r0 = ret.Get(0).(domain.CommitDetail)
69	}
70	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) error); ok {
71		r1 = returnFunc(ctx, p, repo, rev)
72	} else {
73		r1 = ret.Error(1)
74	}
75	return r0, r1
76}
77
78// BrowseService_GetCommit_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCommit'
79type BrowseService_GetCommit_Call struct {
80	*mock.Call
81}
82
83// GetCommit is a helper method to define mock.On call
84//   - ctx context.Context
85//   - p domain.Principal
86//   - repo domain.RepoName
87//   - rev domain.Revision
88func (_e *BrowseService_Expecter) GetCommit(ctx any, p any, repo any, rev any) *BrowseService_GetCommit_Call {
89	return &BrowseService_GetCommit_Call{Call: _e.mock.On("GetCommit", ctx, p, repo, rev)}
90}
91
92func (_c *BrowseService_GetCommit_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision)) *BrowseService_GetCommit_Call {
93	_c.Call.Run(func(args mock.Arguments) {
94		var arg0 context.Context
95		if args[0] != nil {
96			arg0 = args[0].(context.Context)
97		}
98		var arg1 domain.Principal
99		if args[1] != nil {
100			arg1 = args[1].(domain.Principal)
101		}
102		var arg2 domain.RepoName
103		if args[2] != nil {
104			arg2 = args[2].(domain.RepoName)
105		}
106		var arg3 domain.Revision
107		if args[3] != nil {
108			arg3 = args[3].(domain.Revision)
109		}
110		run(
111			arg0,
112			arg1,
113			arg2,
114			arg3,
115		)
116	})
117	return _c
118}
119
120func (_c *BrowseService_GetCommit_Call) Return(commitDetail domain.CommitDetail, err error) *BrowseService_GetCommit_Call {
121	_c.Call.Return(commitDetail, err)
122	return _c
123}
124
125func (_c *BrowseService_GetCommit_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision) (domain.CommitDetail, error)) *BrowseService_GetCommit_Call {
126	_c.Call.Return(run)
127	return _c
128}
129
130// GetTree provides a mock function for the type BrowseService
131func (_mock *BrowseService) GetTree(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision, path domain.TreePath, includeLastCommit bool) (domain.Tree, error) {
132	ret := _mock.Called(ctx, p, repo, rev, path, includeLastCommit)
133
134	if len(ret) == 0 {
135		panic("no return value specified for GetTree")
136	}
137
138	var r0 domain.Tree
139	var r1 error
140	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath, bool) (domain.Tree, error)); ok {
141		return returnFunc(ctx, p, repo, rev, path, includeLastCommit)
142	}
143	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath, bool) domain.Tree); ok {
144		r0 = returnFunc(ctx, p, repo, rev, path, includeLastCommit)
145	} else {
146		r0 = ret.Get(0).(domain.Tree)
147	}
148	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath, bool) error); ok {
149		r1 = returnFunc(ctx, p, repo, rev, path, includeLastCommit)
150	} else {
151		r1 = ret.Error(1)
152	}
153	return r0, r1
154}
155
156// BrowseService_GetTree_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTree'
157type BrowseService_GetTree_Call struct {
158	*mock.Call
159}
160
161// GetTree is a helper method to define mock.On call
162//   - ctx context.Context
163//   - p domain.Principal
164//   - repo domain.RepoName
165//   - rev domain.Revision
166//   - path domain.TreePath
167//   - includeLastCommit bool
168func (_e *BrowseService_Expecter) GetTree(ctx any, p any, repo any, rev any, path any, includeLastCommit any) *BrowseService_GetTree_Call {
169	return &BrowseService_GetTree_Call{Call: _e.mock.On("GetTree", ctx, p, repo, rev, path, includeLastCommit)}
170}
171
172func (_c *BrowseService_GetTree_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision, path domain.TreePath, includeLastCommit bool)) *BrowseService_GetTree_Call {
173	_c.Call.Run(func(args mock.Arguments) {
174		var arg0 context.Context
175		if args[0] != nil {
176			arg0 = args[0].(context.Context)
177		}
178		var arg1 domain.Principal
179		if args[1] != nil {
180			arg1 = args[1].(domain.Principal)
181		}
182		var arg2 domain.RepoName
183		if args[2] != nil {
184			arg2 = args[2].(domain.RepoName)
185		}
186		var arg3 domain.Revision
187		if args[3] != nil {
188			arg3 = args[3].(domain.Revision)
189		}
190		var arg4 domain.TreePath
191		if args[4] != nil {
192			arg4 = args[4].(domain.TreePath)
193		}
194		var arg5 bool
195		if args[5] != nil {
196			arg5 = args[5].(bool)
197		}
198		run(
199			arg0,
200			arg1,
201			arg2,
202			arg3,
203			arg4,
204			arg5,
205		)
206	})
207	return _c
208}
209
210func (_c *BrowseService_GetTree_Call) Return(tree domain.Tree, err error) *BrowseService_GetTree_Call {
211	_c.Call.Return(tree, err)
212	return _c
213}
214
215func (_c *BrowseService_GetTree_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision, path domain.TreePath, includeLastCommit bool) (domain.Tree, error)) *BrowseService_GetTree_Call {
216	_c.Call.Return(run)
217	return _c
218}
219
220// ListCommits provides a mock function for the type BrowseService
221func (_mock *BrowseService) ListCommits(ctx context.Context, p domain.Principal, repo domain.RepoName, params ports.ListCommitsParams) (ports.HistoryPage, error) {
222	ret := _mock.Called(ctx, p, repo, params)
223
224	if len(ret) == 0 {
225		panic("no return value specified for ListCommits")
226	}
227
228	var r0 ports.HistoryPage
229	var r1 error
230	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, ports.ListCommitsParams) (ports.HistoryPage, error)); ok {
231		return returnFunc(ctx, p, repo, params)
232	}
233	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, ports.ListCommitsParams) ports.HistoryPage); ok {
234		r0 = returnFunc(ctx, p, repo, params)
235	} else {
236		r0 = ret.Get(0).(ports.HistoryPage)
237	}
238	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, ports.ListCommitsParams) error); ok {
239		r1 = returnFunc(ctx, p, repo, params)
240	} else {
241		r1 = ret.Error(1)
242	}
243	return r0, r1
244}
245
246// BrowseService_ListCommits_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListCommits'
247type BrowseService_ListCommits_Call struct {
248	*mock.Call
249}
250
251// ListCommits is a helper method to define mock.On call
252//   - ctx context.Context
253//   - p domain.Principal
254//   - repo domain.RepoName
255//   - params ports.ListCommitsParams
256func (_e *BrowseService_Expecter) ListCommits(ctx any, p any, repo any, params any) *BrowseService_ListCommits_Call {
257	return &BrowseService_ListCommits_Call{Call: _e.mock.On("ListCommits", ctx, p, repo, params)}
258}
259
260func (_c *BrowseService_ListCommits_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, params ports.ListCommitsParams)) *BrowseService_ListCommits_Call {
261	_c.Call.Run(func(args mock.Arguments) {
262		var arg0 context.Context
263		if args[0] != nil {
264			arg0 = args[0].(context.Context)
265		}
266		var arg1 domain.Principal
267		if args[1] != nil {
268			arg1 = args[1].(domain.Principal)
269		}
270		var arg2 domain.RepoName
271		if args[2] != nil {
272			arg2 = args[2].(domain.RepoName)
273		}
274		var arg3 ports.ListCommitsParams
275		if args[3] != nil {
276			arg3 = args[3].(ports.ListCommitsParams)
277		}
278		run(
279			arg0,
280			arg1,
281			arg2,
282			arg3,
283		)
284	})
285	return _c
286}
287
288func (_c *BrowseService_ListCommits_Call) Return(historyPage ports.HistoryPage, err error) *BrowseService_ListCommits_Call {
289	_c.Call.Return(historyPage, err)
290	return _c
291}
292
293func (_c *BrowseService_ListCommits_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, params ports.ListCommitsParams) (ports.HistoryPage, error)) *BrowseService_ListCommits_Call {
294	_c.Call.Return(run)
295	return _c
296}
297
298// ListPaths provides a mock function for the type BrowseService
299func (_mock *BrowseService) ListPaths(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision) (domain.PathList, error) {
300	ret := _mock.Called(ctx, p, repo, rev)
301
302	if len(ret) == 0 {
303		panic("no return value specified for ListPaths")
304	}
305
306	var r0 domain.PathList
307	var r1 error
308	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) (domain.PathList, error)); ok {
309		return returnFunc(ctx, p, repo, rev)
310	}
311	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) domain.PathList); ok {
312		r0 = returnFunc(ctx, p, repo, rev)
313	} else {
314		r0 = ret.Get(0).(domain.PathList)
315	}
316	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) error); ok {
317		r1 = returnFunc(ctx, p, repo, rev)
318	} else {
319		r1 = ret.Error(1)
320	}
321	return r0, r1
322}
323
324// BrowseService_ListPaths_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListPaths'
325type BrowseService_ListPaths_Call struct {
326	*mock.Call
327}
328
329// ListPaths is a helper method to define mock.On call
330//   - ctx context.Context
331//   - p domain.Principal
332//   - repo domain.RepoName
333//   - rev domain.Revision
334func (_e *BrowseService_Expecter) ListPaths(ctx any, p any, repo any, rev any) *BrowseService_ListPaths_Call {
335	return &BrowseService_ListPaths_Call{Call: _e.mock.On("ListPaths", ctx, p, repo, rev)}
336}
337
338func (_c *BrowseService_ListPaths_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision)) *BrowseService_ListPaths_Call {
339	_c.Call.Run(func(args mock.Arguments) {
340		var arg0 context.Context
341		if args[0] != nil {
342			arg0 = args[0].(context.Context)
343		}
344		var arg1 domain.Principal
345		if args[1] != nil {
346			arg1 = args[1].(domain.Principal)
347		}
348		var arg2 domain.RepoName
349		if args[2] != nil {
350			arg2 = args[2].(domain.RepoName)
351		}
352		var arg3 domain.Revision
353		if args[3] != nil {
354			arg3 = args[3].(domain.Revision)
355		}
356		run(
357			arg0,
358			arg1,
359			arg2,
360			arg3,
361		)
362	})
363	return _c
364}
365
366func (_c *BrowseService_ListPaths_Call) Return(pathList domain.PathList, err error) *BrowseService_ListPaths_Call {
367	_c.Call.Return(pathList, err)
368	return _c
369}
370
371func (_c *BrowseService_ListPaths_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision) (domain.PathList, error)) *BrowseService_ListPaths_Call {
372	_c.Call.Return(run)
373	return _c
374}
375
376// ListRefs provides a mock function for the type BrowseService
377func (_mock *BrowseService) ListRefs(ctx context.Context, p domain.Principal, repo domain.RepoName, params ports.ListRefsParams) (ports.RefPage, error) {
378	ret := _mock.Called(ctx, p, repo, params)
379
380	if len(ret) == 0 {
381		panic("no return value specified for ListRefs")
382	}
383
384	var r0 ports.RefPage
385	var r1 error
386	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, ports.ListRefsParams) (ports.RefPage, error)); ok {
387		return returnFunc(ctx, p, repo, params)
388	}
389	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, ports.ListRefsParams) ports.RefPage); ok {
390		r0 = returnFunc(ctx, p, repo, params)
391	} else {
392		r0 = ret.Get(0).(ports.RefPage)
393	}
394	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, ports.ListRefsParams) error); ok {
395		r1 = returnFunc(ctx, p, repo, params)
396	} else {
397		r1 = ret.Error(1)
398	}
399	return r0, r1
400}
401
402// BrowseService_ListRefs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListRefs'
403type BrowseService_ListRefs_Call struct {
404	*mock.Call
405}
406
407// ListRefs is a helper method to define mock.On call
408//   - ctx context.Context
409//   - p domain.Principal
410//   - repo domain.RepoName
411//   - params ports.ListRefsParams
412func (_e *BrowseService_Expecter) ListRefs(ctx any, p any, repo any, params any) *BrowseService_ListRefs_Call {
413	return &BrowseService_ListRefs_Call{Call: _e.mock.On("ListRefs", ctx, p, repo, params)}
414}
415
416func (_c *BrowseService_ListRefs_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, params ports.ListRefsParams)) *BrowseService_ListRefs_Call {
417	_c.Call.Run(func(args mock.Arguments) {
418		var arg0 context.Context
419		if args[0] != nil {
420			arg0 = args[0].(context.Context)
421		}
422		var arg1 domain.Principal
423		if args[1] != nil {
424			arg1 = args[1].(domain.Principal)
425		}
426		var arg2 domain.RepoName
427		if args[2] != nil {
428			arg2 = args[2].(domain.RepoName)
429		}
430		var arg3 ports.ListRefsParams
431		if args[3] != nil {
432			arg3 = args[3].(ports.ListRefsParams)
433		}
434		run(
435			arg0,
436			arg1,
437			arg2,
438			arg3,
439		)
440	})
441	return _c
442}
443
444func (_c *BrowseService_ListRefs_Call) Return(refPage ports.RefPage, err error) *BrowseService_ListRefs_Call {
445	_c.Call.Return(refPage, err)
446	return _c
447}
448
449func (_c *BrowseService_ListRefs_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, params ports.ListRefsParams) (ports.RefPage, error)) *BrowseService_ListRefs_Call {
450	_c.Call.Return(run)
451	return _c
452}
453
454// OpenBlob provides a mock function for the type BrowseService
455func (_mock *BrowseService) OpenBlob(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision, path domain.TreePath) (domain.BlobInfo, io.ReadCloser, error) {
456	ret := _mock.Called(ctx, p, repo, rev, path)
457
458	if len(ret) == 0 {
459		panic("no return value specified for OpenBlob")
460	}
461
462	var r0 domain.BlobInfo
463	var r1 io.ReadCloser
464	var r2 error
465	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath) (domain.BlobInfo, io.ReadCloser, error)); ok {
466		return returnFunc(ctx, p, repo, rev, path)
467	}
468	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath) domain.BlobInfo); ok {
469		r0 = returnFunc(ctx, p, repo, rev, path)
470	} else {
471		r0 = ret.Get(0).(domain.BlobInfo)
472	}
473	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath) io.ReadCloser); ok {
474		r1 = returnFunc(ctx, p, repo, rev, path)
475	} else {
476		if ret.Get(1) != nil {
477			r1 = ret.Get(1).(io.ReadCloser)
478		}
479	}
480	if returnFunc, ok := ret.Get(2).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision, domain.TreePath) error); ok {
481		r2 = returnFunc(ctx, p, repo, rev, path)
482	} else {
483		r2 = ret.Error(2)
484	}
485	return r0, r1, r2
486}
487
488// BrowseService_OpenBlob_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'OpenBlob'
489type BrowseService_OpenBlob_Call struct {
490	*mock.Call
491}
492
493// OpenBlob is a helper method to define mock.On call
494//   - ctx context.Context
495//   - p domain.Principal
496//   - repo domain.RepoName
497//   - rev domain.Revision
498//   - path domain.TreePath
499func (_e *BrowseService_Expecter) OpenBlob(ctx any, p any, repo any, rev any, path any) *BrowseService_OpenBlob_Call {
500	return &BrowseService_OpenBlob_Call{Call: _e.mock.On("OpenBlob", ctx, p, repo, rev, path)}
501}
502
503func (_c *BrowseService_OpenBlob_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision, path domain.TreePath)) *BrowseService_OpenBlob_Call {
504	_c.Call.Run(func(args mock.Arguments) {
505		var arg0 context.Context
506		if args[0] != nil {
507			arg0 = args[0].(context.Context)
508		}
509		var arg1 domain.Principal
510		if args[1] != nil {
511			arg1 = args[1].(domain.Principal)
512		}
513		var arg2 domain.RepoName
514		if args[2] != nil {
515			arg2 = args[2].(domain.RepoName)
516		}
517		var arg3 domain.Revision
518		if args[3] != nil {
519			arg3 = args[3].(domain.Revision)
520		}
521		var arg4 domain.TreePath
522		if args[4] != nil {
523			arg4 = args[4].(domain.TreePath)
524		}
525		run(
526			arg0,
527			arg1,
528			arg2,
529			arg3,
530			arg4,
531		)
532	})
533	return _c
534}
535
536func (_c *BrowseService_OpenBlob_Call) Return(blobInfo domain.BlobInfo, readCloser io.ReadCloser, err error) *BrowseService_OpenBlob_Call {
537	_c.Call.Return(blobInfo, readCloser, err)
538	return _c
539}
540
541func (_c *BrowseService_OpenBlob_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision, path domain.TreePath) (domain.BlobInfo, io.ReadCloser, error)) *BrowseService_OpenBlob_Call {
542	_c.Call.Return(run)
543	return _c
544}
545
546// ResolveRevision provides a mock function for the type BrowseService
547func (_mock *BrowseService) ResolveRevision(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision) (domain.ResolvedRevision, error) {
548	ret := _mock.Called(ctx, p, repo, rev)
549
550	if len(ret) == 0 {
551		panic("no return value specified for ResolveRevision")
552	}
553
554	var r0 domain.ResolvedRevision
555	var r1 error
556	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) (domain.ResolvedRevision, error)); ok {
557		return returnFunc(ctx, p, repo, rev)
558	}
559	if returnFunc, ok := ret.Get(0).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) domain.ResolvedRevision); ok {
560		r0 = returnFunc(ctx, p, repo, rev)
561	} else {
562		r0 = ret.Get(0).(domain.ResolvedRevision)
563	}
564	if returnFunc, ok := ret.Get(1).(func(context.Context, domain.Principal, domain.RepoName, domain.Revision) error); ok {
565		r1 = returnFunc(ctx, p, repo, rev)
566	} else {
567		r1 = ret.Error(1)
568	}
569	return r0, r1
570}
571
572// BrowseService_ResolveRevision_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResolveRevision'
573type BrowseService_ResolveRevision_Call struct {
574	*mock.Call
575}
576
577// ResolveRevision is a helper method to define mock.On call
578//   - ctx context.Context
579//   - p domain.Principal
580//   - repo domain.RepoName
581//   - rev domain.Revision
582func (_e *BrowseService_Expecter) ResolveRevision(ctx any, p any, repo any, rev any) *BrowseService_ResolveRevision_Call {
583	return &BrowseService_ResolveRevision_Call{Call: _e.mock.On("ResolveRevision", ctx, p, repo, rev)}
584}
585
586func (_c *BrowseService_ResolveRevision_Call) Run(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision)) *BrowseService_ResolveRevision_Call {
587	_c.Call.Run(func(args mock.Arguments) {
588		var arg0 context.Context
589		if args[0] != nil {
590			arg0 = args[0].(context.Context)
591		}
592		var arg1 domain.Principal
593		if args[1] != nil {
594			arg1 = args[1].(domain.Principal)
595		}
596		var arg2 domain.RepoName
597		if args[2] != nil {
598			arg2 = args[2].(domain.RepoName)
599		}
600		var arg3 domain.Revision
601		if args[3] != nil {
602			arg3 = args[3].(domain.Revision)
603		}
604		run(
605			arg0,
606			arg1,
607			arg2,
608			arg3,
609		)
610	})
611	return _c
612}
613
614func (_c *BrowseService_ResolveRevision_Call) Return(resolvedRevision domain.ResolvedRevision, err error) *BrowseService_ResolveRevision_Call {
615	_c.Call.Return(resolvedRevision, err)
616	return _c
617}
618
619func (_c *BrowseService_ResolveRevision_Call) RunAndReturn(run func(ctx context.Context, p domain.Principal, repo domain.RepoName, rev domain.Revision) (domain.ResolvedRevision, error)) *BrowseService_ResolveRevision_Call {
620	_c.Call.Return(run)
621	return _c
622}

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 2

Tags 45

↑↓ moveenter openesc close