diff --git a/lib/github_check_run_service.rb b/lib/github_check_run_service.rb index 6d8feca..8cb2355 100644 --- a/lib/github_check_run_service.rb +++ b/lib/github_check_run_service.rb @@ -17,7 +17,7 @@ def run )['id'] @summary = @report_adapter.summary(@report) @annotations = @report_adapter.annotations(@report) - @conclusion = @report_adapter.conslusion(@report) + @conclusion = @report_adapter.conclusion(@report) @percent = @report_adapter.lines_covered_percent(@report) @client.patch( diff --git a/lib/report_adapter.rb b/lib/report_adapter.rb index c82843d..58d51db 100644 --- a/lib/report_adapter.rb +++ b/lib/report_adapter.rb @@ -6,7 +6,7 @@ class << self CONCLUSION_TYPES = { failure: 'failure', success: 'success' }.freeze ANNOTATION_LEVEL = { notice: 'notice', warning: 'warning', failure: 'failure' }.freeze - def conslusion(report) + def conclusion(report) lines_covered_percent(report) >= lines_minimum_percent(report).to_f ? CONCLUSION_TYPES[:success] : CONCLUSION_TYPES[:failure] end diff --git a/spec/report_adapter_spec.rb b/spec/report_adapter_spec.rb index 137c0e8..6324cd1 100644 --- a/spec/report_adapter_spec.rb +++ b/spec/report_adapter_spec.rb @@ -13,8 +13,8 @@ let(:adapter) { ReportAdapter } - it '.conslusion' do - result = adapter.conslusion(report) + it '.conclusion' do + result = adapter.conclusion(report) expect(result).to eq('success') end