mock_http_server 1.0.0
mock_http_server: ^1.0.0 copied to clipboard
A modern, enterprise-grade HTTP, HTTPS, and WebSocket mock server package for Dart and Flutter. Support queue-based matching, path/regex routing, middleware, delay/bandwidth simulation, GraphQL operat [...]
Use this package as an executable
Install it
You can install the package from the command line:
dart pub global activate mock_http_serverUse it
The package has the following executables:
$ mock_http_server
Use this package as a library
Depend on it
Run this command:
With Dart:
$ dart pub add mock_http_serverWith Flutter:
$ flutter pub add mock_http_serverThis will add a line like this to your package's pubspec.yaml (and run an implicit dart pub get):
dependencies:
mock_http_server: ^1.0.0Alternatively, 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:mock_http_server/mock_http_server.dart';