Skip to content

Commit

Permalink
jest config [nfc]: Clarify organizing-comments a bit.
Browse files Browse the repository at this point in the history
These comment lines are each meant to label a group of several
properties in the config: see 0f829fe where they were introduced.

Originally that was done by having each heading as a single line
attached to a stanza.  That perhaps worked when first introduced,
but it promptly stopped working at cc5d382, when one stanza was
broken up to make room for a longer comment on a particular
property.  The comment no longer looked like a heading for a group
of lines, and as a result in b9d3dba it got attached to just the
one line right after it.

So, try making the headings bigger, in particular to try to make it
clear that their scope is at a higher level than the comments on
individual properties in each section.
  • Loading branch information
gnprice committed May 23, 2021
1 parent 88db034 commit 4854a89
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ const projectForPlatform = platform => {
// 3) assign `global.Promise` back to what we saved in step 1
preset: platform === 'ios' ? './jest/presetIos' : './jest/presetAndroid',

// Finding and transforming source code.
//
//
// Config for finding and transforming source code.
//

testPathIgnorePatterns: ['/node_modules/', '/src/__tests__/lib/', '-testlib.js$'],

// When some source file foo.js says `import 'bar'`, Jest looks in the
Expand All @@ -64,7 +68,11 @@ const projectForPlatform = platform => {
},
transformIgnorePatterns: [transformIgnorePattern],

// The runtime test environment.
//
//
// Config for the runtime test environment.
//

globals: {
__TEST__: true,
},
Expand Down

0 comments on commit 4854a89

Please sign in to comment.