Retrieve the normalized PullRequestStatus for the provided github status state.
(state: StatusState)
| 268 | |
| 269 | /** A map of all of the statuses indexed by their names. */ |
| 270 | const statusMap = new Map<string, PullRequestStatusInfo['statuses'][number]>(); |
| 271 | |
| 272 | statusCheckRollup.contexts.nodes |
| 273 | .sort((a, b) => { |
| 274 | const aTimestamp = Date.parse(a.completedAt || a.createdAt || '0'); |
| 275 | const bTimestamp = Date.parse(b.completedAt || b.createdAt || '0'); |
| 276 | return aTimestamp - bTimestamp; |
| 277 | }) |
| 278 | .forEach((context) => { |
| 279 | switch (context.__typename) { |
| 280 | case 'CheckRun': |
| 281 | statusMap.set(`check:${context.name}`, { |
| 282 | type: 'check' as const, |
| 283 | name: context.name, |
| 284 | status: normalizeGithubCheckState(context.conclusion, context.status), |
no outgoing calls
no test coverage detected