Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Meta
create-react-app
Commits
a0efbebe
Commit
a0efbebe
authored
8 years ago
by
Patrick Mackinder
Committed by
Dan Abramov
8 years ago
Browse files
Options
Download
Email Patches
Plain Diff
Add collectCoverageFrom option to collect coverage on files without any tests. (#961)
parent
0bd593ba
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
packages/react-scripts/utils/createJestConfig.js
+1
-0
packages/react-scripts/utils/createJestConfig.js
with
1 addition
and
0 deletions
+1
-0
packages/react-scripts/utils/createJestConfig.js
+
1
-
0
View file @
a0efbebe
...
...
@@ -18,6 +18,7 @@ module.exports = (resolve, rootDir, isEjecting) => {
const
setupTestsFile
=
pathExists
.
sync
(
paths
.
testsSetup
)
?
'
<rootDir>/src/setupTests.js
'
:
undefined
;
const
config
=
{
collectCoverageFrom
:
[
'
src/**/*.{js,jsx}
'
],
moduleFileExtensions
:
[
'
jsx
'
,
'
js
'
,
'
json
'
],
moduleNameMapper
:
{
'
^.+
\\
.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$
'
:
resolve
(
'
config/jest/FileStub.js
'
),
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment