Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 35 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,40 @@
"version-check": "node ./scripts/tasks/version-check.js"
},
"jest": {
"projects": [
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried keeping just one project but even the newest version of Jest (21 alpha) crashes with just one project so I had to inline the config back. cc @cpojer in case this is not known.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, it's a known issue you already filed jestjs/jest#4117 😉

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, thanks. I remember a few issues were recently closed so I wasn't sure. Sorry I didn't check 😛

"<rootDir>/scripts/jest/stack.config.json",
"<rootDir>/scripts/jest/fiber.config.json"
]
"modulePathIgnorePatterns": [
"/.module-cache/",
"<rootDir>/build/",
"<rootDir>/scripts/rollup/shims/",
"<rootDir>/scripts/bench/"
],
"transform": {
".*": "./scripts/jest/preprocessor.js"
},
"setupFiles": [
"./scripts/jest/setup.js",
"./scripts/jest/environment.js"
],
"setupTestFrameworkScriptFile": "./scripts/jest/test-framework-setup.js",
"testRegex": "/__tests__/.*(\\.js|coffee|ts)$",
"moduleFileExtensions": [
"js",
"json",
"node",
"coffee",
"ts"
],
"roots": [
"<rootDir>/eslint-rules",
"<rootDir>/mocks",
"<rootDir>/scripts",
"<rootDir>/src",
"node_modules/fbjs"
],
"collectCoverageFrom": [
"src/**/*.js",
"!src/__mocks__/vendor/third_party/*.js",
"!src/test/*.js"
],
"timers": "fake"
}
}
38 changes: 0 additions & 38 deletions scripts/jest/fiber.config.json

This file was deleted.

6 changes: 0 additions & 6 deletions scripts/jest/fiber.setup.js → scripts/jest/setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,6 @@

// We want to globally mock this but jest doesn't let us do that by default
// for a file that already exists. So we have to explicitly mock it.
jest.mock('ReactDOMFeatureFlags', () => {
const flags = require.requireActual('ReactDOMFeatureFlags');
return Object.assign({}, flags, {
useFiber: true,
});
});
jest.mock('ReactFeatureFlags', () => {
const flags = require.requireActual('ReactFeatureFlags');
return Object.assign({}, flags, {
Expand Down
38 changes: 0 additions & 38 deletions scripts/jest/stack.config.json

This file was deleted.

14 changes: 0 additions & 14 deletions scripts/jest/stack.setup.js

This file was deleted.

2 changes: 1 addition & 1 deletion scripts/rollup/packaging.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const facebookWWWSrcDependencies = [
// these files need to be copied to the react-native build
const reactNativeSrcDependencies = [
// TODO: copy this to RN repository and delete from React
'src/renderers/shared/stack/PooledClass.js',
'src/renderers/native/PooledClass.js',
'src/renderers/shared/fiber/isomorphic/ReactTypes.js',
'src/renderers/native/ReactNativeTypes.js',
];
Expand Down
Loading