()
| 62 | } |
| 63 | |
| 64 | func (stat *Statistor) ColorString() string { |
| 65 | var s strings.Builder |
| 66 | s.WriteString(fmt.Sprintf("[stat] %s took %d s, request total: %s, finish: %s/%s(%s skipped), found: %s, check: %s, failed: %s", |
| 67 | logs.GreenLine(stat.BaseUrl), |
| 68 | stat.EndTime-stat.StartTime, |
| 69 | logs.YellowBold(strconv.Itoa(int(stat.ReqTotal))), |
| 70 | logs.YellowBold(strconv.Itoa(stat.End)), |
| 71 | logs.YellowBold(strconv.Itoa(stat.Total)), |
| 72 | logs.YellowLine(strconv.Itoa(stat.Skipped)), |
| 73 | logs.YellowBold(strconv.Itoa(stat.FoundNumber)), |
| 74 | logs.YellowBold(strconv.Itoa(stat.CheckNumber)), |
| 75 | logs.YellowBold(strconv.Itoa(int(stat.FailedNumber))))) |
| 76 | |
| 77 | if stat.FuzzyNumber != 0 { |
| 78 | s.WriteString(", fuzzy: " + logs.Yellow(strconv.Itoa(stat.FuzzyNumber))) |
| 79 | } |
| 80 | if stat.FilteredNumber != 0 { |
| 81 | s.WriteString(", filtered: " + logs.Yellow(strconv.Itoa(stat.FilteredNumber))) |
| 82 | } |
| 83 | if stat.WafedNumber != 0 { |
| 84 | s.WriteString(", wafed: " + logs.Yellow(strconv.Itoa(stat.WafedNumber))) |
| 85 | } |
| 86 | return s.String() |
| 87 | } |
| 88 | func (stat *Statistor) String() string { |
| 89 | var s strings.Builder |
| 90 | s.WriteString(fmt.Sprintf("[stat] %s took %d s, request total: %d, finish: %d/%d(%d skipped), found: %d, check: %d, failed: %d", |
no test coverage detected