Skip to content

Commit

Permalink
Merge pull request #35 from MichaelAlexanderBanuelos/fix/typo-in-insi…
Browse files Browse the repository at this point in the history
…ghts-workflows

fix: fixes typo in method name
  • Loading branch information
grezar committed Mar 2, 2023
2 parents 7a3dd8e + ff97993 commit 1c0baae
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions insight.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
)

type Insights interface {
ListSummaryMetricsForWorkflos(ctx context.Context, projectSlug string, options InsightsListSummaryMetricsOptions) (*SummaryMetricsList, error)
ListSummaryMetricsForWorkflows(ctx context.Context, projectSlug string, options InsightsListSummaryMetricsOptions) (*SummaryMetricsList, error)
ListSummaryMetricsForWorkflowJobs(ctx context.Context, projectSlug, workflowName string, options InsightsListSummaryMetricsOptions) (*SummaryMetricsList, error)
GetTestMetricsForWorkflows(ctx context.Context, projectSlug, workflowName string, options InsightsGetTestMetricsOptions) (*TestMetrics, error)
ListWorkflowRuns(ctx context.Context, projectSlug, workflowName string, options InsightsListWorkflowRunsOptions) (*WorkflowRunList, error)
Expand Down Expand Up @@ -75,7 +75,7 @@ func (o InsightsListSummaryMetricsOptions) valid() error {
return nil
}

func (s *insights) ListSummaryMetricsForWorkflos(ctx context.Context, projectSlug string, options InsightsListSummaryMetricsOptions) (*SummaryMetricsList, error) {
func (s *insights) ListSummaryMetricsForWorkflows(ctx context.Context, projectSlug string, options InsightsListSummaryMetricsOptions) (*SummaryMetricsList, error) {
if err := options.valid(); err != nil {
return nil, err
}
Expand Down
6 changes: 3 additions & 3 deletions insight_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ func Test_insights_ListSummaryMetricsForWorkflows(t *testing.T) {
})

ctx := context.Background()
sml, err := client.Insights.ListSummaryMetricsForWorkflos(ctx, projectSlug, InsightsListSummaryMetricsOptions{
sml, err := client.Insights.ListSummaryMetricsForWorkflows(ctx, projectSlug, InsightsListSummaryMetricsOptions{
PageToken: String("1"),
AllBranches: Bool(true),
ReportingWindow: ReportingWindow(Last90Days),
})
if err != nil {
t.Errorf("Insights.ListSummaryMetricsForWorkflos got error: %v", err)
t.Errorf("Insights.ListSummaryMetricsForWorkflows got error: %v", err)
}

want := &SummaryMetricsList{
Expand All @@ -46,7 +46,7 @@ func Test_insights_ListSummaryMetricsForWorkflows(t *testing.T) {
}

if !cmp.Equal(sml, want) {
t.Errorf("Insights.ListSummaryMetricsForWorkflos got %+v, want %+v", sml, want)
t.Errorf("Insights.ListSummaryMetricsForWorkflows got %+v, want %+v", sml, want)
}
}

Expand Down
12 changes: 6 additions & 6 deletions mocks/insight.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 1c0baae

Please sign in to comment.