{"id":4469,"url":"https://github.com/apentle/react-native-babel-jest","last_synced_at":"2025-05-01T22:30:24.445Z","repository":{"id":57335603,"uuid":"58367210","full_name":"apentle/react-native-babel-jest","owner":"apentle","description":"Simple testing configuration for React Native with Jest","archived":false,"fork":false,"pushed_at":"2017-03-17T10:24:38.000Z","size":40,"stargazers_count":19,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-22T17:52:07.650Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://blog.apentle.com/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/apentle.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-05-09T10:05:31.000Z","updated_at":"2023-09-11T12:37:15.000Z","dependencies_parsed_at":"2022-09-07T17:34:10.859Z","dependency_job_id":null,"html_url":"https://github.com/apentle/react-native-babel-jest","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apentle%2Freact-native-babel-jest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apentle%2Freact-native-babel-jest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apentle%2Freact-native-babel-jest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apentle%2Freact-native-babel-jest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/apentle","download_url":"https://codeload.github.com/apentle/react-native-babel-jest/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251954646,"owners_count":21670845,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-01-05T20:17:13.535Z","updated_at":"2025-05-01T22:30:24.072Z","avatar_url":"https://github.com/apentle.png","language":"JavaScript","funding_links":[],"categories":["Components"],"sub_categories":["Utils \u0026 Infra"],"readme":"# react-native-babel-jest\n[![Build Status](https://travis-ci.org/apentle/react-native-babel-jest.svg?branch=master)](https://travis-ci.org/apentle/react-native-babel-jest) [![Coverage Status](https://coveralls.io/repos/github/apentle/react-native-babel-jest/badge.svg?branch=master)](https://coveralls.io/github/apentle/react-native-babel-jest?branch=master)\n\nSimple testing configuration for React Native with Jest\n\n## Installation\n```bash\nnpm i --save-dev react-native-babel-jest jest-cli\n```\n\n## Usage\nAdd configuration to `package.json` file\n```javascript\n{\n  \"scripts\": {\n    \"test\": \"jest\"\n  },\n  ...\n  \"jest\": {\n    \"scriptPreprocessor\": \"\u003crootDir\u003e/node_modules/react-native-babel-jest\",\n    \"setupFiles\": [\n      \"\u003crootDir\u003e/node_modules/react-native-babel-jest/env.js\"\n    ],\n    \"automock\": true,\n    \"unmockedModulePathPatterns\": [\n      \"react\",\n      \"enzyme\",\n      \"promise\",\n      \"source-map\"\n    ]\n  }\n}\n```\nWrite your test in `__tests__` folder, run test command\n```bash\nnpm test\n```\n\n## Recommendation\nWe recommend you using `enzyme` to render components, and `enzyme-to-json` to make snapshot testing. See more in the example below.\n\n## Example\n[See this example](https://github.com/apentle/react-native-babel-jest/blob/master/Example/README.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapentle%2Freact-native-babel-jest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fapentle%2Freact-native-babel-jest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapentle%2Freact-native-babel-jest/lists"}