From 7324c22ff91c572b4022a1d22c6c7751a73ad76a Mon Sep 17 00:00:00 2001 From: Adnan-Bacic Date: Wed, 11 Jan 2023 10:13:15 -0800 Subject: [PATCH] add-coverage-to-gitignore (#35809) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Summary: There is a large amount of autogenerated files in the coverage folder when running `jest --coverage`. This folder is also in .gitignore for react projects created with `create-react-app` Originally suggested here: https://github.com/react-native-community/discussions-and-proposals/discussions/569 ## Changelog [GENERAL] [ADDED] - Added "coverage" folder generated på `jest --coverage` to .gitignore Pull Request resolved: https://github.com/facebook/react-native/pull/35809 Test Plan: 1. cd template 2. yarn 3. yarn test --coverage Im not sure why many of the files in the template folder have an underscore(_) in the filenames instead of a dot(.). When creating a react-native project they have a dot. So if you run the above commands, the coverage folder will not be ignored since its not in `.gitingore` but in `_gitignore`. However, if you temporarily create a `.gitignore` file, you will see that the coverage folder is ignored. 4. Temporarily create `.gitignore` file to verify that coverage folder is ignored Reviewed By: cortinico Differential Revision: D42454560 Pulled By: jacdebug fbshipit-source-id: 0be007d3ba3dde47814c0ce0fb8b0ff9f67d637b --- template/_gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/template/_gitignore b/template/_gitignore index 16f8c30773d344..0cab2ac6fc46cd 100644 --- a/template/_gitignore +++ b/template/_gitignore @@ -61,3 +61,6 @@ yarn-error.log # Temporary files created by Metro to check the health of the file watcher .metro-health-check* + +# testing +/coverage