-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13943 from Expensify/Rory-SimplifyTestWorkflow
[No QA] Simplify test workflow using Jest --shard flag
- Loading branch information
Showing
16 changed files
with
16,637 additions
and
14,015 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
const testFileExtension = '[jt]s?(x)'; | ||
module.exports = { | ||
// TODO: change this back to preset: 'react-native' once we upgrade to React Native >= 0.71.2 | ||
preset: '@testing-library/react-native', | ||
testMatch: [ | ||
`<rootDir>/tests/ui/**/*.${testFileExtension}`, | ||
`<rootDir>/tests/unit/**/*.${testFileExtension}`, | ||
`<rootDir>/tests/actions/**/*.${testFileExtension}`, | ||
`<rootDir>/?(*.)+(spec|test).${testFileExtension}`, | ||
], | ||
transform: { | ||
'^.+\\.jsx?$': 'babel-jest', | ||
}, | ||
transformIgnorePatterns: [ | ||
'<rootDir>/node_modules/(?!react-native)/', | ||
], | ||
testPathIgnorePatterns: [ | ||
'<rootDir>/node_modules', | ||
], | ||
globals: { | ||
__DEV__: true, | ||
WebSocket: {}, | ||
}, | ||
fakeTimers: { | ||
enableGlobally: true, | ||
doNotFake: ['nextTick'], | ||
}, | ||
testEnvironment: 'jsdom', | ||
setupFiles: [ | ||
'<rootDir>/jest/setup.js', | ||
], | ||
setupFilesAfterEnv: [ | ||
'@testing-library/jest-native/extend-expect', | ||
], | ||
cacheDirectory: '<rootDir>/.jest-cache', | ||
}; |
Oops, something went wrong.