littlelink-server icon indicating copy to clipboard operation
littlelink-server copied to clipboard

JS Test - Deprecation Warning

Open timothystewart6 opened this issue 2 years ago • 0 comments

Looks like we need to fix parts of the API that are being deprecated in react 18

https://github.com/techno-tim/littlelink-server/runs/7006518148?check_suite_focus=true

PASS src/components/Sort/__test__/Sort.test.js
  ● Console
    console.error
      Warning: ReactDOM.render is no longer supported in React 18. Use createRoot instead. Until you switch to the new API, your app will behave as if it's running React 17. Learn more: https://reactjs.org/link/switch-to-createroot
      22 |
      23 |   test('renders without exploding', () => {
    > 24 |     render(<Sort />, container);
         |     ^
      [25](https://github.com/techno-tim/littlelink-server/runs/7006518148?check_suite_focus=true#step:4:26) |   });
      [26](https://github.com/techno-tim/littlelink-server/runs/7006518148?check_suite_focus=true#step:4:27) |
      [27](https://github.com/techno-tim/littlelink-server/runs/7006518148?check_suite_focus=true#step:4:28) |   test('Sorts Buttons by order', () => {
      at printWarning (node_modules/react-dom/cjs/react-dom.development.js:86:30)
      at error (node_modules/react-dom/cjs/react-dom.development.js:60:7)
      at render (node_modules/react-dom/cjs/react-dom.development.js:[29](https://github.com/techno-tim/littlelink-server/runs/7006518148?check_suite_focus=true#step:4:30)670:5)
      at Object.<anonymous> (src/components/Sort/__test__/Sort.test.js:24:5)

timothystewart6 avatar Jun 22 '22 15:06 timothystewart6