Simple bindings to make Mountebank easier to use from Python Mountebank is a tool which makes it easier to write tests for Microservice architectures by spawning processes which imitate servers locally.
npm install -g mountebank --production
pip install mountebank-python
Imposter - A process which listens on a port (pretending to be a server) Imposter has multiple stubs A stub has multiple "predicates" and "responses" Predicates define which stub matches when a stub matches it uses its next response
Run mb
to start mountebank
In python:
- Define your imposters (example given in mountebank.py)
- Initialize a microservice object
- Make requests to it
Example usage in mountebank.py