Download react-instantsearch/examples/react-native/tests/App.test.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 356 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-instantsearch/examples/react-native/tests/App.test.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset@1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-instantsearch/examples/react-native/tests/App.test.js
-
curl -L -o App.test.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-instantsearch/examples/react-native/tests/App.test.js
356 Bytes
| import 'react-native'; | |
| import React from 'react'; | |
| // Note: test renderer must be required after react-native. | |
| import renderer from 'react-test-renderer'; | |
| import App from '../App'; | |
| jest.useFakeTimers(); | |
| Date.now = jest.fn(() => 0); | |
| test('renders correctly', () => { | |
| const tree = renderer.create(<App />).toJSON(); | |
| expect(tree).toMatchSnapshot(); | |
| }); | |