* Expands the list of selected runs to runs incl. configuration from config.multiple.
(selectedRuns, config)
| 46 | * Expands the list of selected runs to runs incl. configuration from config.multiple. |
| 47 | */ |
| 48 | prepareRuns(selectedRuns, config) { |
| 49 | selectedRuns.forEach((selectedRun) => { |
| 50 | const runConfig = []; |
| 51 | const runName = []; |
| 52 | |
| 53 | if (selectedRun === 'all') { |
| 54 | Object.keys(config.multiple).forEach(name => { |
| 55 | runName.push(name); |
| 56 | runConfig.push(config.multiple[name]); |
| 57 | }); |
| 58 | } else { |
| 59 | runName.push(selectedRun.split(':')[0]); |
| 60 | runConfig.push(config.multiple[runName[0]]); |
| 61 | } |
| 62 | |
| 63 | for (let i = 0; i < runConfig.length; i++) { |
| 64 | if (!runConfig[i]) { |
| 65 | throw new Error(`run ${runName[i]} was not configured in "multiple" section of config`); |
| 66 | } |
| 67 | |
| 68 | this.addRun(createRun(runName[i], runConfig[i])); |
| 69 | } |
| 70 | }); |
| 71 | |
| 72 | return this; |
| 73 | } |
| 74 | |
| 75 | /** |
| 76 | * Expands runs via the `chunks` property to multiple runs. If config.chunks is a numeric |
no test coverage detected