From 65fe53f5c0c5178e7179a6e5b180a3f509c646f3 Mon Sep 17 00:00:00 2001 From: Nico Jansen Date: Fri, 13 Oct 2023 20:29:19 +0200 Subject: [PATCH] docs: remove mention of old `runCore` --- docs/ProgrammaticApi.md | 4 ++-- e2e/__tests__/__snapshots__/runProgrammatically.test.ts.snap | 2 +- e2e/run-programmatically/jest.mjs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/ProgrammaticApi.md b/docs/ProgrammaticApi.md index 8d4864c8ede6..096494f0da6d 100644 --- a/docs/ProgrammaticApi.md +++ b/docs/ProgrammaticApi.md @@ -18,7 +18,7 @@ import jest from 'jest'; const {globalConfig, configs} = await jest.readConfigs(process.argv, ['.']); const {result} = await jest.runCore(globalConfig, configs); -console.log(`runCore success, ${result.numPassedTests} passed tests.`); +console.log(`run success, ${result.numPassedTests} passed tests.`); ``` This example runs Jest as the normal Jest command line interface (CLI) would. @@ -84,7 +84,7 @@ It takes in in an array of command line arguments (for example, `process.argv`) import {runCLI} from 'jest'; const {results, globalConfig} = await runCLI(process.argv, ['.']); -console.log(`runCore success, ${result.numPassedTests} passed tests.`); +console.log(`run success, ${result.numPassedTests} passed tests.`); ``` ### `runCore` \[function] diff --git a/e2e/__tests__/__snapshots__/runProgrammatically.test.ts.snap b/e2e/__tests__/__snapshots__/runProgrammatically.test.ts.snap index ea4a3237cc67..1c2ee60beb86 100644 --- a/e2e/__tests__/__snapshots__/runProgrammatically.test.ts.snap +++ b/e2e/__tests__/__snapshots__/runProgrammatically.test.ts.snap @@ -1,6 +1,6 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`createJest run programmatically: stdout 1`] = `"runCore success, 1 passed tests."`; +exports[`createJest run programmatically: stdout 1`] = `"run success, 1 passed tests."`; exports[`createJest run programmatically: summary 1`] = ` "Test Suites: 1 passed, 1 total diff --git a/e2e/run-programmatically/jest.mjs b/e2e/run-programmatically/jest.mjs index f337d710ef8c..61681bfffd76 100644 --- a/e2e/run-programmatically/jest.mjs +++ b/e2e/run-programmatically/jest.mjs @@ -14,4 +14,4 @@ jest.globalConfig = { ...jest.globalConfig, }; const {results} = await jest.run(); -console.log(`runCore success, ${results.numPassedTests} passed tests.`); +console.log(`run success, ${results.numPassedTests} passed tests.`);