(sample: Sample, index: number, total: number)
| 144 | } |
| 145 | |
| 146 | async runWithSample(sample: Sample, index: number, total: number) { |
| 147 | const cwd = this.getRunDirectory(); |
| 148 | let sampleFile = path.basename(sample.path); |
| 149 | let shouldSkip = this.shouldSkipTest(sample); |
| 150 | const additionalFiles = this.additionalFiles(sample); |
| 151 | |
| 152 | this.printRunMessage(sample, index, total, cwd, shouldSkip); |
| 153 | |
| 154 | if (shouldSkip) { |
| 155 | return; |
| 156 | } |
| 157 | |
| 158 | shell.cp("-R", this.language.base, cwd); |
| 159 | shell.cp.apply(null, _.concat(sample.path, additionalFiles, cwd)); |
| 160 | |
| 161 | await inDir(cwd, async () => { |
| 162 | await this.runQuicktype(sampleFile, sample.additionalRendererOptions); |
| 163 | |
| 164 | try { |
| 165 | await this.test( |
| 166 | sampleFile, |
| 167 | sample.additionalRendererOptions, |
| 168 | additionalFiles |
| 169 | ); |
| 170 | } catch (e) { |
| 171 | failWith("Fixture threw an exception", { error: e }); |
| 172 | } |
| 173 | }); |
| 174 | |
| 175 | shell.rm("-rf", cwd); |
| 176 | } |
| 177 | } |
| 178 | |
| 179 | class JSONFixture extends LanguageFixture { |
nothing calls this directly
no test coverage detected
searching dependent graphs…