{"repo":"donfuxx/Mockinizer","free":true,"listed":false,"github":"https://github.com/donfuxx/Mockinizer","clone":"git clone https://github.com/donfuxx/Mockinizer.git","description":"An okhttp / retrofit api call mocking library","language":"Kotlin","stars":194,"topics":["mock","mock-server","mockwebserver","rest-api","restful-api","okhttp3","retrofit2","testing","android-library","agile-development"],"license":"Apache-2.0","category":"api-integrations-sdks","readme_excerpt":"Mockinizer An OkHttpClient / RetroFit web api call mocking library that uses Square's MockWebServer to provide mocked responses by using Interceptors. What is it? Mockinizer helps Android developers to build apps with web api calls that use OkHttpClient / RetroFit by allowing them to quickly mock some web api responses with MockWebServer. Mockinizer allows to mock only specific api calls, while other api calls will still call the original server. This is particularily usefull in the following scenarios: - You are working on a new feature that needs to call new not yet existing apis. With Mockinizer you can quickly swap in the new desired mocked api responses while other api calls will still use the real server - You want to test error cases for existing apis. With Mockinizer you can can quickly mock an error 500 response or an 401 Unauthorized for selected api requests and verify if your app handles them gracefully - You want to call a mocked api for unit testing and isolate those from the webserver Setup 1. Add jitpack.io repository: Add jitpack.io repository in root build.gradle : 2. Add Mockinizer gradle dependency Add the below code in the app module's build.gradle (Usually you want to implement it only in debug builds and not release builds) At the time of writing the latest mockinizer version was 1.1.0, you can get latest release version here: https://github.com/donfuxx/Mockinizer/releases You may also need to add a MockWebServer dependency in your app module: 3. Define","default_branch":null,"files":null,"tree":[],"storefront":"/r/donfuxx","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/donfuxx/Mockinizer/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}