(preflight?: TestPreflightResult)
| 210 | } |
| 211 | |
| 212 | function createTestSelectionInfo(preflight?: TestPreflightResult): TestSelectionInfo | undefined { |
| 213 | if (!preflight || preflight.totalTests === 0) { |
| 214 | return undefined; |
| 215 | } |
| 216 | |
| 217 | const discoveredItems = collectResolvedTestSelectors(preflight); |
| 218 | const discoveryEvent = createTestDiscoveryFragment(preflight); |
| 219 | const hasExplicitSelection = |
| 220 | preflight.selectors.onlyTesting.length > 0 || preflight.selectors.skipTesting.length > 0; |
| 221 | |
| 222 | return { |
| 223 | ...(hasExplicitSelection ? { selected: discoveredItems } : {}), |
| 224 | ...(discoveryEvent |
| 225 | ? { |
| 226 | discovered: { |
| 227 | total: discoveryEvent.total, |
| 228 | items: discoveryEvent.tests, |
| 229 | }, |
| 230 | } |
| 231 | : {}), |
| 232 | }; |
| 233 | } |
| 234 | |
| 235 | interface FinalizeXcodebuildResultOptions { |
| 236 | started: StartedPipeline; |
no test coverage detected