(cs *iostreams.ColorScheme, status Status, conclusion Conclusion)
| 571 | type colorFunc func(string) string |
| 572 | |
| 573 | func Symbol(cs *iostreams.ColorScheme, status Status, conclusion Conclusion) (string, colorFunc) { |
| 574 | noColor := func(s string) string { return s } |
| 575 | if status == Completed { |
| 576 | switch conclusion { |
| 577 | case Success: |
| 578 | return cs.SuccessIconWithColor(noColor), cs.Green |
| 579 | case Skipped, Neutral: |
| 580 | return "-", cs.Muted |
| 581 | default: |
| 582 | return cs.FailureIconWithColor(noColor), cs.Red |
| 583 | } |
| 584 | } |
| 585 | |
| 586 | return "*", cs.Yellow |
| 587 | } |
| 588 | |
| 589 | func PullRequestForRun(client *api.Client, repo ghrepo.Interface, run Run) (int, error) { |
| 590 | type response struct { |
no test coverage detected