Skip to content

Commit a663e34

Browse files
committed
feat(mock): Implementa GetIssue en MockVCSClient (#40)
1 parent e61dc04 commit a663e34

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

internal/infrastructure/dependency/gomod_analyzer_test.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,14 @@ func (m *MockVCSClient) GetFileStatsBetweenTags(ctx context.Context, previousTag
8686
return args.Get(0).(*models.FileStatistics), args.Error(1)
8787
}
8888

89+
func (m *MockVCSClient) GetIssue(ctx context.Context, issueNumber int) (*models.Issue, error) {
90+
args := m.Called(ctx, issueNumber)
91+
if args.Get(0) == nil {
92+
return nil, args.Error(1)
93+
}
94+
return args.Get(0).(*models.Issue), args.Error(1)
95+
}
96+
8997
func TestGoModAnalyzer_Name(t *testing.T) {
9098
analyzer := NewGoModAnalyzer()
9199
assert.Equal(t, "go.mod", analyzer.Name())

0 commit comments

Comments
 (0)