MCPcopy
hub / github.com/jestjs/jest / matchErrorSnapshot

Function matchErrorSnapshot

packages/jest-config/src/__tests__/normalize.test.ts:2034–2046  ·  view source on GitHub ↗
(callback: {
    (): Promise<{
      hasDeprecationWarnings: boolean;
      options: Config.ProjectConfig & Config.GlobalConfig;
    }>;
    (): Promise<{
      hasDeprecationWarnings: boolean;
      options: Config.ProjectConfig & Config.GlobalConfig;
    }>;
    (): any;
  })

Source from the content-addressed store, hash-verified

2032
2033describe('extensionsToTreatAsEsm', () => {
2034 async function matchErrorSnapshot(callback: {
2035 (): Promise<{
2036 hasDeprecationWarnings: boolean;
2037 options: Config.ProjectConfig & Config.GlobalConfig;
2038 }>;
2039 (): Promise<{
2040 hasDeprecationWarnings: boolean;
2041 options: Config.ProjectConfig & Config.GlobalConfig;
2042 }>;
2043 (): any;
2044 }) {
2045 await expect(callback()).rejects.toThrowErrorMatchingSnapshot();
2046 }
2047
2048 it('should pass valid config through', async () => {
2049 const {options} = await normalize(

Callers 1

normalize.test.tsFile · 0.85

Calls 3

expectFunction · 0.85
callbackFunction · 0.50

Tested by

no test coverage detected