(
/** @type {Error | null} */ err,
/** @type {import("../").Stats} */ stats
)
| 196 | } |
| 197 | |
| 198 | const onCompiled = ( |
| 199 | /** @type {Error | null} */ err, |
| 200 | /** @type {import("../").Stats} */ stats |
| 201 | ) => { |
| 202 | const deprecations = deprecationTracker(); |
| 203 | if (err) return done(err); |
| 204 | const jsonStats = stats.toJson({ |
| 205 | errorDetails: true |
| 206 | }); |
| 207 | if ( |
| 208 | checkArrayExpectation( |
| 209 | testDirectory, |
| 210 | jsonStats, |
| 211 | "error", |
| 212 | "Error", |
| 213 | options, |
| 214 | done |
| 215 | ) |
| 216 | ) { |
| 217 | return; |
| 218 | } |
| 219 | if ( |
| 220 | checkArrayExpectation( |
| 221 | testDirectory, |
| 222 | jsonStats, |
| 223 | "warning", |
| 224 | "Warning", |
| 225 | options, |
| 226 | done |
| 227 | ) |
| 228 | ) { |
| 229 | return; |
| 230 | } |
| 231 | if ( |
| 232 | checkArrayExpectation( |
| 233 | testDirectory, |
| 234 | { deprecations }, |
| 235 | "deprecation", |
| 236 | "Deprecation", |
| 237 | options, |
| 238 | done |
| 239 | ) |
| 240 | ) { |
| 241 | return; |
| 242 | } |
| 243 | |
| 244 | function runCompiler( |
| 245 | /** @type {(err: EXPECTED_ANY, stats?: EXPECTED_ANY) => void} */ callback |
| 246 | ) { |
| 247 | fakeUpdateLoaderOptions.updateIndex++; |
| 248 | const deprecationTracker = deprecationTracking.start(); |
| 249 | compiler.run((err, _stats) => { |
| 250 | const stats = /** @type {import("../").Stats} */ (_stats); |
| 251 | const deprecations = deprecationTracker(); |
| 252 | if (err) return callback(err); |
| 253 | const jsonStats = stats.toJson({ |
| 254 | errorDetails: true |
| 255 | }); |
nothing calls this directly
no test coverage detected