From 0ce5ea58040b32946138399b286dcd743f50cb2a Mon Sep 17 00:00:00 2001 From: Ran Yitzhaki Date: Wed, 26 Sep 2018 01:39:18 +0300 Subject: [PATCH 1/3] document --runTestsByPath CLI parameter --- docs/CLI.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/CLI.md b/docs/CLI.md index 44e584f87d19..55fd24e9ceb8 100644 --- a/docs/CLI.md +++ b/docs/CLI.md @@ -227,6 +227,12 @@ Run tests with specified reporters. [Reporter options](configuration#reporters-a Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. From 48a8afe0dc77e1325d5d430f7753a1d303776f37 Mon Sep 17 00:00:00 2001 From: Ran Yitzhaki Date: Wed, 26 Sep 2018 01:43:08 +0300 Subject: [PATCH 2/3] update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2f72957d6254..e5eb1bbe4d90 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,7 @@ ### Chore & Maintenance +- `[docs]` Document `--runTestsByPath` CLI parameter ([#7046](https://github.com/facebook/jest/pull/7046)) - `[docs]` Fix babel-core installation instructions ([#6745](https://github.com/facebook/jest/pull/6745)) - `[docs]` Explain how to rewrite assertions to avoid large irrelevant diff ([#6971](https://github.com/facebook/jest/pull/6971)) - `[examples]` add example using Babel 7 ([#6983](https://github.com/facebook/jest/pull/6983)) From ac40b7876cf4cb1e23db4ff3ddf9f0ac3de48eab Mon Sep 17 00:00:00 2001 From: Ran Yitzhaki Date: Wed, 26 Sep 2018 09:45:04 +0300 Subject: [PATCH 3/3] update versioned docs --- website/versioned_docs/version-22.0/CLI.md | 6 ++++++ website/versioned_docs/version-22.2/CLI.md | 6 ++++++ website/versioned_docs/version-22.3/CLI.md | 6 ++++++ website/versioned_docs/version-22.4/CLI.md | 6 ++++++ website/versioned_docs/version-23.0/CLI.md | 6 ++++++ website/versioned_docs/version-23.1/CLI.md | 6 ++++++ website/versioned_docs/version-23.2/CLI.md | 6 ++++++ website/versioned_docs/version-23.3/CLI.md | 6 ++++++ website/versioned_docs/version-23.5/CLI.md | 6 ++++++ website/versioned_docs/version-23.6/CLI.md | 6 ++++++ 10 files changed, 60 insertions(+) diff --git a/website/versioned_docs/version-22.0/CLI.md b/website/versioned_docs/version-22.0/CLI.md index 25b51d536005..243a47485720 100644 --- a/website/versioned_docs/version-22.0/CLI.md +++ b/website/versioned_docs/version-22.0/CLI.md @@ -190,6 +190,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-22.2/CLI.md b/website/versioned_docs/version-22.2/CLI.md index d519cca9c9d9..583b1cbf5f89 100644 --- a/website/versioned_docs/version-22.2/CLI.md +++ b/website/versioned_docs/version-22.2/CLI.md @@ -192,6 +192,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-22.3/CLI.md b/website/versioned_docs/version-22.3/CLI.md index d30d8a93c3ef..0fc4afa2573c 100644 --- a/website/versioned_docs/version-22.3/CLI.md +++ b/website/versioned_docs/version-22.3/CLI.md @@ -192,6 +192,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-22.4/CLI.md b/website/versioned_docs/version-22.4/CLI.md index 058528562823..af4b6c06c783 100644 --- a/website/versioned_docs/version-22.4/CLI.md +++ b/website/versioned_docs/version-22.4/CLI.md @@ -210,6 +210,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-23.0/CLI.md b/website/versioned_docs/version-23.0/CLI.md index d685ba087e83..adabd0e54aae 100644 --- a/website/versioned_docs/version-23.0/CLI.md +++ b/website/versioned_docs/version-23.0/CLI.md @@ -214,6 +214,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-23.1/CLI.md b/website/versioned_docs/version-23.1/CLI.md index a5efc3ee97c6..c3487f6a06b6 100644 --- a/website/versioned_docs/version-23.1/CLI.md +++ b/website/versioned_docs/version-23.1/CLI.md @@ -218,6 +218,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-23.2/CLI.md b/website/versioned_docs/version-23.2/CLI.md index 484fd86aa0e8..78ead5fc140d 100644 --- a/website/versioned_docs/version-23.2/CLI.md +++ b/website/versioned_docs/version-23.2/CLI.md @@ -222,6 +222,12 @@ Run tests from one or more projects. Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-23.3/CLI.md b/website/versioned_docs/version-23.3/CLI.md index 3c67703f4bfc..d54560131968 100644 --- a/website/versioned_docs/version-23.3/CLI.md +++ b/website/versioned_docs/version-23.3/CLI.md @@ -228,6 +228,12 @@ Run tests with specified reporters. [Reporter options](configuration#reporters-a Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-23.5/CLI.md b/website/versioned_docs/version-23.5/CLI.md index e1935760238b..adf0576d6933 100644 --- a/website/versioned_docs/version-23.5/CLI.md +++ b/website/versioned_docs/version-23.5/CLI.md @@ -228,6 +228,12 @@ Run tests with specified reporters. [Reporter options](configuration#reporters-a Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing. diff --git a/website/versioned_docs/version-23.6/CLI.md b/website/versioned_docs/version-23.6/CLI.md index 35a54f9df84e..e29ccb22ef8e 100644 --- a/website/versioned_docs/version-23.6/CLI.md +++ b/website/versioned_docs/version-23.6/CLI.md @@ -228,6 +228,12 @@ Run tests with specified reporters. [Reporter options](configuration#reporters-a Alias: `-i`. Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests. This can be useful for debugging. +### `--runTestsByPath` + +Run only the tests that were specified with their exact paths. + +_Note: The default regex matching works fine on small runs, but becomes slow if provided with multiple patterns and/or against a lot of tests. This option replaces the regex matching logic and by that optimizes the time it takes Jest to filter specific test files_ + ### `--setupTestFrameworkScriptFile=` The path to a module that runs some code to configure or set up the testing framework before each test. Beware that files imported by the setup script will not be mocked during testing.