|
1 | 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP |
2 | 2 |
|
| 3 | +exports[`ScriptTransformer (in sync mode) throws an error if \`process\` isn't defined 1`] = ` |
| 4 | +"<red><bold>● Invalid synchronous transformer module:</></> |
| 5 | +<red> \\"skipped-required-props-preprocessor-only-async\\" specified in the \\"transform\\" object of Jest configuration</> |
| 6 | +<red> must export a \`process\` function.</> |
| 7 | +<red> <bold>Code Transformation Documentation:</></> |
| 8 | +<red> https://jestjs.io/docs/code-transformation</> |
| 9 | +<red></>" |
| 10 | +`; |
| 11 | +
|
3 | 12 | exports[`ScriptTransformer in async mode, passes expected transform options to getCacheKey 1`] = ` |
4 | 13 | [MockFunction] { |
5 | 14 | "calls": Array [ |
@@ -126,7 +135,11 @@ const TRANSFORMED = { |
126 | 135 |
|
127 | 136 | exports[`ScriptTransformer in async mode, uses the supplied preprocessor 2`] = `module.exports = "react";`; |
128 | 137 |
|
129 | | -exports[`ScriptTransformer in async mode, warns of unparseable inlined source maps from the preprocessor 1`] = `jest-transform: The source map produced for the file /fruits/banana.js by preprocessor-with-sourcemaps was invalid. Proceeding without source mapping for that file.`; |
| 138 | +exports[`ScriptTransformer in async mode, warns of unparseable inlined source maps from the preprocessor 1`] = ` |
| 139 | +[33m[1m● Invalid source map:[22m[39m |
| 140 | +[33m The source map for "/fruits/banana.js" returned by "preprocessor-with-sourcemaps" is invalid.[39m |
| 141 | +[33m Proceeding without source mapping for that file.[39m |
| 142 | +`; |
130 | 143 |
|
131 | 144 | exports[`ScriptTransformer passes expected transform options to getCacheKey 1`] = ` |
132 | 145 | [MockFunction] { |
@@ -340,6 +353,24 @@ exports[`ScriptTransformer passes expected transform options to getCacheKeyAsync |
340 | 353 | } |
341 | 354 | `; |
342 | 355 |
|
| 356 | +exports[`ScriptTransformer throws an error if createTransformer returns object without \`process\` method 1`] = ` |
| 357 | +"<red><bold>● Invalid transformer module:</></> |
| 358 | +<red> \\"skipped-required-create-transformer-props-preprocessor\\" specified in the \\"transform\\" object of Jest configuration</> |
| 359 | +<red> must export a \`process\` or \`processAsync\` or \`createTransformer\` function.</> |
| 360 | +<red> <bold>Code Transformation Documentation:</></> |
| 361 | +<red> https://jestjs.io/docs/code-transformation</> |
| 362 | +<red></>" |
| 363 | +`; |
| 364 | +
|
| 365 | +exports[`ScriptTransformer throws an error if neither \`process\` nor \`processAsync\` is defined 1`] = ` |
| 366 | +"<red><bold>● Invalid transformer module:</></> |
| 367 | +<red> \\"skipped-required-props-preprocessor\\" specified in the \\"transform\\" object of Jest configuration</> |
| 368 | +<red> must export a \`process\` or \`processAsync\` or \`createTransformer\` function.</> |
| 369 | +<red> <bold>Code Transformation Documentation:</></> |
| 370 | +<red> https://jestjs.io/docs/code-transformation</> |
| 371 | +<red></>" |
| 372 | +`; |
| 373 | +
|
343 | 374 | exports[`ScriptTransformer transforms a file async properly 1`] = ` |
344 | 375 | /* istanbul ignore next */ |
345 | 376 | function cov_25u22311x4() { |
@@ -688,6 +719,14 @@ const TRANSFORMED = { |
688 | 719 |
|
689 | 720 | exports[`ScriptTransformer uses the supplied preprocessor 2`] = `module.exports = "react";`; |
690 | 721 |
|
691 | | -exports[`ScriptTransformer warns of unparseable inlined source maps from the async preprocessor 1`] = `jest-transform: The source map produced for the file /fruits/banana.js by async-preprocessor-with-sourcemaps was invalid. Proceeding without source mapping for that file.`; |
| 722 | +exports[`ScriptTransformer warns of unparseable inlined source maps from the async preprocessor 1`] = ` |
| 723 | +[33m[1m● Invalid source map:[22m[39m |
| 724 | +[33m The source map for "/fruits/banana.js" returned by "async-preprocessor-with-sourcemaps" is invalid.[39m |
| 725 | +[33m Proceeding without source mapping for that file.[39m |
| 726 | +`; |
692 | 727 |
|
693 | | -exports[`ScriptTransformer warns of unparseable inlined source maps from the preprocessor 1`] = `jest-transform: The source map produced for the file /fruits/banana.js by preprocessor-with-sourcemaps was invalid. Proceeding without source mapping for that file.`; |
| 728 | +exports[`ScriptTransformer warns of unparseable inlined source maps from the preprocessor 1`] = ` |
| 729 | +[33m[1m● Invalid source map:[22m[39m |
| 730 | +[33m The source map for "/fruits/banana.js" returned by "preprocessor-with-sourcemaps" is invalid.[39m |
| 731 | +[33m Proceeding without source mapping for that file.[39m |
| 732 | +`; |
0 commit comments