http_mock_adapter 0.6.1 copy "http_mock_adapter: ^0.6.1" to clipboard
http_mock_adapter: ^0.6.1 copied to clipboard

A simple to use mocking package for Dio intended to be used in tests. It provides various types and methods to declaratively mock request-response communication.

Use this package as a library

Depend on it

Run this command:

With Dart:

 $ dart pub add http_mock_adapter

With Flutter:

 $ flutter pub add http_mock_adapter

This will add a line like this to your package's pubspec.yaml (and run an implicit dart pub get):

dependencies:
  http_mock_adapter: ^0.6.1

Alternatively, your editor might support dart pub get or flutter pub get. Check the docs for your editor to learn more.

Import it

Now in your Dart code, you can use:

import 'package:http_mock_adapter/http_mock_adapter.dart';
164
likes
150
points
197k
downloads

Publisher

verified publisherlomsa.com

Weekly Downloads

A simple to use mocking package for Dio intended to be used in tests. It provides various types and methods to declaratively mock request-response communication.

Repository (GitHub)
View/report issues
Contributing

Documentation

API reference

License

MIT (license)

Dependencies

collection, dio, http_parser, logger

More

Packages that depend on http_mock_adapter