{"id":14110060,"url":"https://github.com/infinitered/awesome-react-testing","last_synced_at":"2025-02-26T11:45:49.960Z","repository":{"id":66219343,"uuid":"170145595","full_name":"infinitered/awesome-react-testing","owner":"infinitered","description":"React and React Native testing tools and strategies","archived":false,"fork":false,"pushed_at":"2019-03-07T07:05:21.000Z","size":76,"stargazers_count":71,"open_issues_count":0,"forks_count":9,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-04-14T04:43:21.028Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/infinitered.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2019-02-11T14:46:36.000Z","updated_at":"2024-03-06T11:51:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"cab6a61d-5a44-438b-bd1f-2b6c2f165550","html_url":"https://github.com/infinitered/awesome-react-testing","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/infinitered%2Fawesome-react-testing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/infinitered%2Fawesome-react-testing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/infinitered%2Fawesome-react-testing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/infinitered%2Fawesome-react-testing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/infinitered","download_url":"https://codeload.github.com/infinitered/awesome-react-testing/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240848996,"owners_count":19867616,"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-08-14T10:02:38.517Z","updated_at":"2025-02-26T11:45:49.908Z","avatar_url":"https://github.com/infinitered.png","language":null,"funding_links":[],"categories":["Other Lists"],"sub_categories":["TeX Lists"],"readme":"\n![Awesome](https://camo.githubusercontent.com/13c4e50d88df7178ae1882a203ed57b641674f94/68747470733a2f2f63646e2e7261776769742e636f6d2f73696e647265736f726875732f617765736f6d652f643733303566333864323966656437386661383536353265336136336531353464643865383832392f6d656469612f62616467652e737667)\n[![All Contributors](https://img.shields.io/badge/all_contributors-2-orange.svg?style=flat-square)](#contributors)\n\n# Awesome React Testing\n\nA collection of React and React Native testing tools and strategies.\n\n\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n**Table of Contents**\n\n- [Unit Testing](#unit-testing)\n  - [Jest](#jest)\n    - [Fetch Mock](#fetch-mock)\n  - [Other Frameworks](#other-frameworks)\n  - [Assertion](#assertion)\n  - [Runner](#runner)\n- [Regression Testing](#regression-testing)\n- [Blackbox Testing](#blackbox-testing)\n- [Greybox Testing](#greybox-testing)\n- [Linters](#linters)\n  - [Regular](#regular)\n  - [A11y](#a11y)\n- [Maintence Managers](#maintence-managers)\n- [Environment Helpers](#environment-helpers)\n- [Performance](#performance)\n- [Quality Checks](#quality-checks)\n- [Coverage Reporting](#coverage-reporting)\n- [Chaos Testing](#chaos-testing)\n- [Production Checking / Testing](#production-checking--testing)\n- [Audits](#audits)\n- [Contributors](#contributors)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n## Tutorials\n\nFor web:\n\n* [Testing React Components](https://www.valentinog.com/blog/testing-react/) - by Valentino Gagliardi\n* [Fullstack React - Testing Chapter](https://www.fullstackreact.com/30-days-of-react/day-22/) - Day 22 of \"30 Days of React\"\n* [Testing JavaScript with Kent C. Dodds](https://testingjavascript.com/) - Paid course \n\nFor React Native:\n\n* [Testing React Native Apps](https://jestjs.io/docs/en/tutorial-react-native) - Jest guide to React Native app testing\n\n## Unit Testing\n\nChoose one of these to be the primary framework you will be using to test your React and React Native apps. The most popular, by far, is Jest.\n\n### Jest\n\nWebsite: https://jestjs.io/\nWorks on projects using: Babel, TypeScript, Node, React, Angular, Vue and more.  Based on Mocha\nCheatsheet:  https://github.com/sapegin/jest-cheat-sheet\n\n#### Fetch Mock\n\n* [Jest Fetch Mock](https://github.com/jefflau/jest-fetch-mock) - Jest mock for the fetch polyfill.\n\nMore on Jest at [AWESOME-JEST](https://github.com/jest-community/awesome-jest)\n\n### Other Frameworks\n\n* [mocha](https://github.com/mochajs/mocha) - Simple, flexible, fun javascript test framework for node.js \u0026 the browser.\n* [jasmine](https://github.com/jasmine/jasmine) - DOM-less simple JavaScript testing framework.\n* [qunit](https://github.com/jquery/qunit) - An easy-to-use JavaScript Unit Testing framework.\n* [prova](https://github.com/azer/prova) - Node \u0026 Browser test runner based on Tape and Browserify\n* [DalekJS](https://github.com/dalekjs/dalek) - Automated cross browser functional testing with JavaScript\n* [Protractor](https://github.com/angular/protractor) - Protractor is an end-to-end test framework for AngularJS applications.\n* [tape](https://github.com/substack/tape) - Tap-producing test harness for node and browsers.\n* [TestCafe](https://github.com/DevExpress/testcafe) - Automated browser testing for the modern web development stack.\n* [ava](https://github.com/avajs/ava) - 🚀 Futuristic JavaScript test runner\n* [intern](https://github.com/theintern/intern) - A next-generation code testing stack for JavaScript.\n\n### Assertion\n\nAssertion libraries give you tools to ensure things are correct. For example, they may give you matchers such as `expect(true).toBeTruthy()`.\n\n* [chai](https://github.com/chaijs/chai) - BDD / TDD assertion framework for node.js and the browser that can be paired with any testing framework.\n* [chai-immutable](https://github.com/astorije/chai-immutable)\n* [Enzyme](http://airbnb.io/enzyme/index.html) - Enzyme is a JavaScript Testing utility for React that makes it easier to assert, manipulate, and traverse your React Components' output.\n* [react testing library](https://github.com/kentcdodds/react-testing-library) - Simple and complete React DOM testing utilities that encourage good testing practices.\n  * [React Native Version](https://github.com/callstack/react-native-testing-library)\n* [Sinon.JS](https://github.com/sinonjs/sinon) - Test spies, stubs, and mocks for JavaScript.\n* [expect.js](https://github.com/Automattic/expect.js) - Minimalistic BDD-style assertions for Node.JS and the browser.\n* [React Unit](https://github.com/pzavolinsky/react-unit) - Lightweight unit test library for ReactJS\n* [skin-deep](https://github.com/glenjamin/skin-deep) - Testing helpers for use with React's shallowRender test utils.\n* [Unexpected React](https://github.com/bruderstein/unexpected-react/) - Plugin for [http://unexpected.js.org](http://unexpected.js.org/) to enable testing the full React virtual DOM.\n\n### Browser-based Testing Tools\n\nThese allow you to run tests right in a real browser, to build full integration tests.\n\n* [phantomjs](https://github.com/ariya/phantomjs) - Scriptable Headless WebKit.\n* [slimerjs](https://github.com/laurentj/slimerjs) - A PhantomJS-like tool running Gecko.\n* [casperjs](https://github.com/casperjs/casperjs) - Navigation scripting \u0026 testing utility for PhantomJS and SlimerJS.\n* [zombie](https://github.com/assaf/zombie) - Insanely fast, full-stack, headless browser testing using node.js.\n* [totoro](https://github.com/totorojs/totoro) - A simple and stable cross-browser testing tool.\n* [karma](https://github.com/karma-runner/karma) - Spectacular Test Runner for JavaScript.\n* [nightwatch](https://github.com/nightwatchjs/nightwatch) - UI automated testing framework based on node.js and selenium webdriver.\n* [yolpo](http://www.yolpo.com) - A statement-by-statement javascript interpreter in the browser.\n\n## Snapshot Testing\n\nThese tools allow you to take \"snapshots\" of components and other data and verify that it remains the same between updates.\n\nFor web:\n\n* [storyshots](https://github.com/storybooks/storybook/tree/next/addons)\n* [testStateMachine in react-automata](https://github.com/MicheleBertoli/react-automata)\n\nFor React Native:\n\n* [react-native-view-shot](https://github.com/gre/react-native-view-shot)\n\n\n## Blackbox Testing\n\nThese tools allow you to write end-to-end integration tests -- without having any insight into the implementation details.\n\nFor React Native:\n\n* [Appium](http://appium.io/)\n\n## Greybox Testing\n\nThese tools are like the blackbox testing tools, except they integrate with internals of the web app to provide more consistency.\n\nFor web:\n\n* [Cypress](https://www.cypress.io/)\n\nFor React Native:\n\n* [Detox](https://github.com/wix/Detox)\n\n## Linters and Formatters\n\nLinters catch errors and protect against common problems. Formatters will reformat your code to ensure consistency.\n\n### Linters\n\n* [ESLint](https://github.com/eslint/eslint)\n* [JSHint](https://github.com/jshint/jshint)\n* [Standard](https://github.com/standard/standard)\n* [Clinton](https://github.com/SamVerschueren/clinton)\n\n### Formatters\n\n* [Prettier](https://github.com/prettier/prettier)\n\n### A11y (accessibility)\n\n* [jsx-a11y](https://github.com/evcohen/eslint-plugin-jsx-a11y)\n* [react-native-a11y](https://github.com/FormidableLabs/eslint-plugin-react-native-a11y)\n\n## Maintenance Managers\n\nThese tools automate tedious tasks like dependency upgrades.\n\n* [DangerJS](https://github.com/danger/danger)\n* [GreenKeeper.io](https://greenkeeper.io/)\n* [Dependabot](https://dependabot.com/)\n* [updtr](https://github.com/peerigon/updtr)\n* [npm-check](https://github.com/dylang/npm-check)\n* [Madge](https://github.com/pahen/madge)\n* [Renovate](https://github.com/renovatebot/renovate)\n\n## Environment Helpers\n\nThese packages help you verify that your environment matches the expected environment for the project (for example, Node versions, etc).\n\n* [Solidarity](https://github.com/infinitered/solidarity)\n* [EnvInfo](https://github.com/tabrindle/envinfo)\n\n## Performance\n\nPerformance tools help you get the most speed out of your React and React Native apps.\n\nFor web:\n\n* [Web Page Test](https://www.webpagetest.org/)\n* [Insights](https://developers.google.com/speed/pagespeed/insights/)\n* [BenchmarkJS](https://benchmarkjs.com/)\n\n## Quality Checks\n\nThese tools will check for code quality scores.\n\n* [JS Inspect](https://github.com/danielstjules/jsinspect)\n* [buddy.js](https://github.com/danielstjules/buddy.js)\n\n## Coverage Reporting\n\nCoverage tools will alert you when you have untested code.\n\n* [CodeCov](https://codecov.io/) - Coverage reporting service.\n* [istanbul](https://github.com/gotwarlost/istanbul) - Yet another JS code coverage tool.\n* [blanket](https://github.com/alex-seville/blanket) - A simple code coverage library for javascript. Designed to be easy to install and use, for both browser and nodejs.\n* [JSCover](https://github.com/tntim96/JSCover) - JSCover is a tool that measures code coverage for JavaScript programs.\n\n## Chaos Testing\n\nChaos testing ensures your tests are resilient to random data and interaction.\n\n* [Psuedo-localization](https://github.com/tryggvigy/pseudo-localization)\n* [Naughty Strings](https://github.com/minimaxir/big-list-of-naughty-strings)\n* [testcheck-js](https://github.com/leebyron/testcheck-js)\n  * [Flow to testcheck](https://github.com/unbounce/babel-plugin-transform-flow-to-gen)\n\nFor web:\n\n* [Service Fabric](https://docs.microsoft.com/en-us/azure/service-fabric/service-fabric-testability-overview)\n* [Gremlin](https://www.gremlin.com/)\n* [Chaos Monkey](https://github.com/Netflix/chaosmonkey)\n\nFor React Native:\n\n* [ClusterFuzz](https://github.com/google/clusterfuzz)\n\n## Production Checking / Testing\n\nThese tools will allow you to see errors that happen in production apps.\n\nFor web:\n\n* [Honeybadger](https://www.honeybadger.io/)\n* [Errorception](https://errorception.com/)\n* [Optimizely](https://www.optimizely.com/)\n\nFor mobile:\n\n* [App Center](https://appcenter.ms)\n* [Bug Snag](https://docs.bugsnag.com/platforms/react-native/)\n\n## Audits\n\nAuditing tools will give you information about your code structure.\n\n* [jsx-info](https://www.youtube.com/watch?v=e_vtfYJW9aM\u0026feature=youtu.be)\n\nFor web:\n\n* [Lighthouse](https://www.w3.org/WAI/ER/tools/)\n\n\n## Contributors\n\nThanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\u003c!-- prettier-ignore --\u003e\n\u003ctable\u003e\u003ctr\u003e\u003ctd align=\"center\"\u003e\u003ca href=\"http://gantlaborde.com/\"\u003e\u003cimg src=\"https://avatars0.githubusercontent.com/u/997157?v=4\" width=\"150px;\" alt=\"Gant Laborde\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eGant Laborde\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/infinitered/awesome-react-testing/commits?author=GantMan\" title=\"Documentation\"\u003e📖\u003c/a\u003e\u003c/td\u003e\u003ctd align=\"center\"\u003e\u003ca href=\"https://jamonholmgren.com\"\u003e\u003cimg src=\"https://avatars3.githubusercontent.com/u/1479215?v=4\" width=\"150px;\" alt=\"Jamon Holmgren\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eJamon Holmgren\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"#content-jamonholmgren\" title=\"Content\"\u003e🖋\u003c/a\u003e \u003ca href=\"#ideas-jamonholmgren\" title=\"Ideas, Planning, \u0026 Feedback\"\u003e🤔\u003c/a\u003e\u003c/td\u003e\u003c/tr\u003e\u003c/table\u003e\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\nThis project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finfinitered%2Fawesome-react-testing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finfinitered%2Fawesome-react-testing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finfinitered%2Fawesome-react-testing/lists"}