-
Notifications
You must be signed in to change notification settings - Fork 272
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: cookbook shoutout ready (#1672)
* update cookbook app libs. and fix navigation to network requests examples * Update cookbook/README.md * Update README.md (2) * Update Cookbook's Intro. sec. in docs * upload readme banner * arranging readme assets --------- Co-authored-by: stevegalili <[email protected]>
- Loading branch information
1 parent
bd98be0
commit f314fe0
Showing
8 changed files
with
102 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,30 @@ | ||
# RNTL Cookbook | ||
<p align="center"> | ||
<img alt="banner" src="assets/readme/banner.png" /> | ||
</p> | ||
|
||
This example app gathers recipes from | ||
the [RNTL Cookbook](https://callstack.github.io/react-native-testing-library/cookbook). | ||
# React Native Testing Library Cookbook App | ||
Welcome to the React Native Testing Library (RNTL) Cookbook! This app is designed to provide developers with a collection of best practices, ready-made recipes, and tips & tricks to help you effectively test your React Native applications. Whether you’re just starting out with testing or looking to deepen your skills, this cookbook offers something for everyone. | ||
|
||
Each recipe described in the Cookbook should have a corresponding code example screen in this repo. | ||
|
||
Note: | ||
Since examples will showcase usage of different dependencies, the dependencies in `package.json` | ||
file will grow much larger that in a normal React Native. This is fine 🐶☕️🔥. | ||
|
||
## Running the App | ||
1. Clone the repo `git clone [email protected]:callstack/react-native-testing-library.git` | ||
2. Go to the `examples/cookbook` directory `cd examples/cookbook` | ||
3. Install dependencies `yarn` | ||
4. Run the app `yarn start` | ||
5. Run the app either on iOS or Android by clicking on `i` or `a` in the terminal. | ||
|
||
## How to Contribute | ||
We invite all developers, from beginners to experts, to contribute your own recipes! If you have a clever solution, best practice, or useful tip, we encourage you to: | ||
|
||
1. Submit a Pull Request with your recipe. | ||
2. Join the conversation on GitHub [here](https://github.com/callstack/react-native-testing-library/issues/1624) to discuss ideas, ask questions, or provide feedback. | ||
|
||
## Screenshots From the App | ||
| Home Screen | Phonebook with Net. Req. Example | | ||
|-------------------------------------------------------|-----------------------------------------------------------------| | ||
| ![home-screenshot](assets/readme/home-screenshot.png) | ![phonebook-screenshot](assets/readme/phonebook-screenshot.png) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,29 @@ | ||
# Introduction | ||
|
||
This cookbook is intended to showcase best practices, tips & tricks, and ready-to-use recipes for using React Native Testing Library. | ||
Welcome to the **React Native Testing Library (RNTL) Cookbook**! | ||
This app is your go-to resource for learning how to effectively test React Native applications. | ||
It provides a collection of **best practices**, **ready-made recipes**, and **tips & tricks** to | ||
simplify and improve your testing workflow. Whether you’re a beginner just getting started or a | ||
seasoned developer looking to sharpen your | ||
skills, the Cookbook has something for everyone. | ||
|
||
We invite you to contribute your favorite recipes to the Cookbook. More info [here](https://github.com/callstack/react-native-testing-library/issues/1624). | ||
## What's Inside the Cookbook? | ||
|
||
The Cookbook is currently organized into **three main chapters**: | ||
|
||
- **Basic Recipes**: A great starting point, covering essential testing scenarios such as async | ||
operations and custom render functions. | ||
- **Advanced Recipes**: More complex scenarios like network requests and in the future, navigation | ||
testing and more. | ||
- **State Management Recipes**: Best practices for testing state management libraries | ||
|
||
Each recipe includes a clear explanation along with a corresponding code example to help you get | ||
hands-on with testing. Checkout | ||
the [Cookbook App](https://github.com/callstack/react-native-testing-library/tree/main/examples/cookbook#rntl-cookbook) to see the | ||
recipes in action. | ||
|
||
## What's Next? | ||
|
||
Join the conversation | ||
on [GitHub](https://github.com/callstack/react-native-testing-library/issues/1624) here to discuss | ||
ideas, ask questions, or provide feedback. |