File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ def run
1818 @summary = @report_adapter . summary ( @report )
1919 @annotations = @report_adapter . annotations ( @report )
2020 @conclusion = @report_adapter . conslusion ( @report )
21+ @percent = @report_adapter . lines_covered_percent ( @report )
2122
2223 @client . patch (
2324 "#{ endpoint_url } /#{ id } " ,
@@ -48,7 +49,7 @@ def update_check_payload
4849 completed_at : Time . now . iso8601 ,
4950 conclusion : @conclusion ,
5051 output : {
51- title : CHECK_NAME ,
52+ title : " #{ CHECK_NAME } #{ @percent } %" ,
5253 summary : @summary ,
5354 annotations : @annotations
5455 }
Original file line number Diff line number Diff line change @@ -18,16 +18,16 @@ def annotations(_report)
1818 [ ]
1919 end
2020
21+ def lines_covered_percent ( report )
22+ @lines_covered_percent ||= report . dig ( 'lines' , 'covered_percent' )
23+ end
24+
2125 private
2226
2327 def table_head
2428 "| Type | covered | minimum |\n | ----- | ------- | ------- |"
2529 end
2630
27- def lines_covered_percent ( report )
28- @lines_covered_percent ||= report . dig ( 'lines' , 'covered_percent' )
29- end
30-
3131 def lines_minimum_percent ( report )
3232 @lines_minimum_percent ||= report . dig ( 'lines' , 'minumum_percent' )
3333 end
You can’t perform that action at this time.
0 commit comments