diff --git a/e2e/__tests__/__snapshots__/requireMissingExt.test.ts.snap b/e2e/__tests__/__snapshots__/requireMissingExt.test.ts.snap index 5910c0ef752b..e218c4b17999 100644 --- a/e2e/__tests__/__snapshots__/requireMissingExt.test.ts.snap +++ b/e2e/__tests__/__snapshots__/requireMissingExt.test.ts.snap @@ -13,22 +13,15 @@ FAIL ./test.js See https://jestjs.io/docs/en/configuration#modulefileextensions-array-string - 1 | 'use strict'; - 2 | - > 3 | require('discord.js'); - | ^ - 4 | - 5 | test('dummy', () => { - 6 | expect(1).toBe(1); + 8 | 'use strict'; + 9 | + > 10 | require('discord.js'); + | ^ + 11 | + 12 | test('dummy', () => { + 13 | expect(1).toBe(1); at Resolver.resolveModule (../../packages/jest-resolve/build/index.js:259:17) at Object. (node_modules/discord.js/src/index.js:21:12) - at Object.require (test.js:3:1) - -Test Suites: 1 failed, 1 total -Tests: 0 total -Snapshots: 0 total -Time: 0.847s -Ran all test suites. - + at Object.require (test.js:10:1) `; diff --git a/e2e/__tests__/requireMissingExt.test.ts b/e2e/__tests__/requireMissingExt.test.ts index c0585479751e..a3eb2c264767 100644 --- a/e2e/__tests__/requireMissingExt.test.ts +++ b/e2e/__tests__/requireMissingExt.test.ts @@ -7,7 +7,7 @@ import path from 'path'; import wrap from 'jest-snapshot-serializer-raw'; -import {run} from '../Utils'; +import {extractSummary, run} from '../Utils'; import runJest from '../runJest'; const dir = path.resolve(__dirname, '../require-missing-ext'); @@ -18,6 +18,7 @@ beforeEach(() => { test('shows a proper error from deep requires', () => { const {stderr} = runJest(dir); + const {rest} = extractSummary(stderr); - expect(wrap(stderr)).toMatchSnapshot(); + expect(wrap(rest)).toMatchSnapshot(); });