()
| 239 | } |
| 240 | |
| 241 | async function globalSetup() { |
| 242 | const platform = process.env.E2E_PLATFORM || 'ios'; |
| 243 | if (!['ios', 'android'].includes(platform)) { |
| 244 | throw new Error(`Unsupported E2E_PLATFORM: ${platform}`); |
| 245 | } |
| 246 | |
| 247 | killExistingServer(); |
| 248 | if (process.env.RNU_E2E_SKIP_PREPARE === 'true') { |
| 249 | ensurePreparedArtifacts(platform); |
| 250 | } else { |
| 251 | runPrepareScript(); |
| 252 | } |
| 253 | startServer(); |
| 254 | await waitForServer(); |
| 255 | await warmServer(platform as 'ios' | 'android'); |
| 256 | await detoxGlobalSetup(); |
| 257 | } |
| 258 | |
| 259 | export default globalSetup; |
nothing calls this directly
no test coverage detected