( group: Group, plugin: string, plugins: ScoredReport['plugins'], )
| 39 | } |
| 40 | |
| 41 | export function getSortedGroupAudits( |
| 42 | group: Group, |
| 43 | plugin: string, |
| 44 | plugins: ScoredReport['plugins'], |
| 45 | ): SortableAuditReport[] { |
| 46 | return group.refs |
| 47 | .map(ref => |
| 48 | getSortableAuditByRef( |
| 49 | { |
| 50 | plugin, |
| 51 | slug: ref.slug, |
| 52 | weight: ref.weight, |
| 53 | type: 'audit', |
| 54 | }, |
| 55 | plugins, |
| 56 | ), |
| 57 | ) |
| 58 | .sort(compareCategoryAuditsAndGroups); |
| 59 | } |
| 60 | |
| 61 | export function getSortableGroupByRef( |
| 62 | { plugin, slug, weight }: CategoryRef, |
no test coverage detected