Skip to content

Commit

Permalink
Remove enzyme (#3989)
Browse files Browse the repository at this point in the history
* WIP stuff

* Things

* updated snapshots and tests

* more testing

* more tests

* moved tests to rtl for Creatable

* fixed eslint errors

* updated StateManaged snapshot and basic test

* first pass at StateManaged

* wip tests

* wip tests

* Finish StateManaged

* Fix some things

* Nearly done Select.test.js

* AsyncCreatable done

* Async tests

* Upgrade node on CI

* Try again

* Linting

* Fix last tests

* Setting nvmrc to 12 and re-adding lint-staged

* Update config.yml

* Fix babel config

* Remove loose on babel preset env becasue it's breaking tests for Reasons

Co-authored-by: mitchellhamilton <[email protected]>
Co-authored-by: Tarang Hirani <[email protected]>
  • Loading branch information
3 people authored Mar 28, 2020
1 parent c8d74bd commit fd54f55
Show file tree
Hide file tree
Showing 19 changed files with 3,830 additions and 4,755 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: 2

docker_defaults: &docker_defaults
docker:
- image: cypress/base:8
- image: cypress/base:13.6.0
environment:
TERM: xterm
working_directory: ~/project/repo
Expand All @@ -17,7 +17,7 @@ install_steps: &install_steps
- restore_cache:
name: Restore node_modules cache
keys:
- dependency-cache-{{ .Branch }}-{{ checksum "package.json" }}
- dependency-cache-{{ .Branch }}-{{ checksum "yarn.lock" }}
- dependency-cache-{{ .Branch }}-
- dependency-cache-
- run:
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10
12
7 changes: 2 additions & 5 deletions babel.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ module.exports = {
plugins: [
'emotion',
['@babel/plugin-proposal-class-properties', { loose: true }],
'@babel/plugin-transform-runtime',
],
presets: [
['@babel/preset-env', { loose: true }],
'@babel/preset-react',
'@babel/preset-flow',
],
presets: ['@babel/preset-env', '@babel/preset-react', '@babel/preset-flow'],
};
4 changes: 2 additions & 2 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@
"pretty-proptypes": "^0.5.0",
"raf-schd": "^2.1.0",
"raw-loader": "^2.0.0",
"react": "^16.8.0",
"react": "^16.13.0",
"react-codesandboxer": "^2.0.1",
"react-dom": "^16.8.0",
"react-dom": "^16.13.0",
"react-helmet": "^5.2.0",
"react-markings": "^1.3.0",
"react-router-dom": "^4.2.2",
Expand Down
4 changes: 0 additions & 4 deletions enzymeAdapter.setup.js

This file was deleted.

23 changes: 13 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
"@atlaskit/modal-dialog": "^4.0.3",
"@atlaskit/spinner": "^5.0.0",
"@atlaskit/tooltip": "^9.1.4",
"@babel/cli": "^7.0.0",
"@babel/core": "^7.2.2",
"@babel/plugin-proposal-class-properties": "^7.2.3",
"@babel/plugin-transform-runtime": "^7.8.3",
"@babel/polyfill": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-flow": "^7.0.0",
Expand All @@ -28,13 +28,17 @@
"@emotion/cache": "^10.0.9",
"@emotion/core": "^10.0.9",
"@emotion/css": "^10.0.9",
"@preconstruct/cli": "^1.0.0",
"@testing-library/dom": "7.0.4",
"@testing-library/jest-dom": "5.1.1",
"@testing-library/react": "10.0.1",
"@testing-library/user-event": "^10.0.0",
"babel-core": "^7.0.0-bridge.0",
"babel-eslint": "^9.0.0",
"babel-jest": "^23.6.0",
"babel-loader": "^8.0.0",
"babel-plugin-emotion": "^10.0.9",
"bolt-check": "^0.3.0",
"bundlesize": "^0.17.0",
"chroma-js": "^1.3.6",
"chrono-node": "^1.3.5",
"codesandboxer": "^0.1.1",
Expand All @@ -55,21 +59,20 @@
"flow-bin": "^0.91.0",
"gh-pages": "^1.1.0",
"html-webpack-plugin": "^3.2.0",
"jest": "^24.8.0",
"jest": "^25.1.0",
"jest-emotion": "^10.0.11",
"jest-in-case": "^1.0.2",
"memoize-one": "^5.0.0",
"moment": "^2.20.1",
"node-fetch": "^2.5.0",
"@preconstruct/cli": "^1.0.0",
"pretty-proptypes": "^0.5.0",
"prop-types": "^15.6.0",
"raf": "^3.4.0",
"raf-schd": "^2.1.0",
"raw-loader": "^2.0.0",
"react": "^16.8.0",
"react": "^16.13.0",
"react-codesandboxer": "^2.0.1",
"react-dom": "^16.8.0",
"react-dom": "^16.13.0",
"react-helmet": "^5.2.0",
"react-input-autosize": "^2.2.2",
"react-markings": "^1.3.0",
Expand All @@ -96,8 +99,8 @@
"e2e": "concurrently --kill-others --success=first --names 'SERVER,E2E' 'yarn start --progress=false --no-info' 'yarn test:cypress'",
"test:cypress": "cypress run --spec ./cypress/integration/select_spec.js",
"test:cypress-watch": "node ./node_modules/.bin/cypress open",
"precommit": "flow check && lint-staged",
"postinstall": "preconstruct dev && bolt-check",
"precommit": "flow check",
"postinstall": "preconstruct dev",
"changeset": "changeset",
"version-packages": "changeset version",
"release": "yarn build && changeset publish"
Expand All @@ -121,8 +124,8 @@
"./node_modules"
],
"testRegex": "src/*(/(__tests?__/)([^_].*/)*?[^_][^/]*?\\.(test|spec)?\\.(js?))$",
"setupFiles": [
"./enzymeAdapter.setup.js"
"setupFilesAfterEnv": [
"./test-setup.js"
],
"snapshotSerializers": [
"jest-emotion"
Expand Down
4 changes: 2 additions & 2 deletions packages/react-select/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
"enzyme": "^3.8.0",
"enzyme-to-json": "^3.3.0",
"jest-in-case": "^1.0.2",
"react": "^16.8.0",
"react-dom": "^16.8.0"
"react": "^16.13.0",
"react-dom": "^16.13.0"
},
"peerDependencies": {
"react": "^16.8.0",
Expand Down
Loading

0 comments on commit fd54f55

Please sign in to comment.