Skip to content

Commit

Permalink
chore(buildtool): remove Enzyme
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter Hellstrand committed Jun 18, 2024
1 parent 18d7a5c commit 979e0f8
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 15 deletions.
3 changes: 0 additions & 3 deletions buildtool/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,6 @@ configuration from [config/jest.config.js](./config/jest.config.js) and
adds support for [enzyme](https://enzymejs.github.io/enzyme/) and
[jest-dom-matchers](https://github.com/testing-library/jest-dom).

Enzymes rendering functions `shallow`, `mount` and `render` are available as
globals in the test cases. See [jest.setup.js](./config/jest.setup.js) for details.

Any parameter passed to this command will be forwarded to jest, e.g.
`ffe-buildtool jtest --coverage` will invoke `jest --coverage` behind the
scenes.
Expand Down
10 changes: 0 additions & 10 deletions buildtool/config/jest.setup.js
Original file line number Diff line number Diff line change
@@ -1,11 +1 @@
// do not import these render functions yourself in your test case, or react
// will be get confused and cannot find enzyme.
import { configure, shallow, render, mount } from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';
import '@testing-library/jest-dom';

configure({ adapter: new Adapter() });

global.shallow = shallow;
global.render = render;
global.mount = mount;
2 changes: 0 additions & 2 deletions buildtool/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
"babel-jest": "^29.1.2",
"commander": "^8.3.0",
"copyfiles": "^2.4.1",
"enzyme": "^3.7.0",
"enzyme-adapter-react-16": "^1.7.0",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"postcss-less": "^6.0.0",
Expand Down

0 comments on commit 979e0f8

Please sign in to comment.