mockserver_client
It has docker based image: jamesdbloom/mockserver:mockserver-5.13.*
As pip dependency could be found here: https://pypi.org/project/helix-mockserver-client/
In your requirements.txt or PipFile add helix-mockserver-client>=*.*.*
Basic usage:
import json
from mockserver_client.mockserver_client import (
MockServerFriendlyClient,
mock_request,
mock_response,
times,
)
mock_server = MockServerFriendlyClient('http://127.0.0.1:1080')
mock_server.expect(mock_request(
path="/" + 'item',
method="POST",
body={
"json": {
"client_id": "unitypoint_bwell",
"client_secret": "fake_client_secret",
"grant_type": "client_credentials",
}
},
),
mock_response(
body=json.dumps(
{
"token_type": "bearer",
"access_token": "fake access_token",
"expires_in": 54000,
}
)
),
timing=times(1),
)
How to pull the image with Docker:
docker pull jamesdbloom/mockserver:mockserver-5.13.2
How to start the server locally with Docker:
docker run -dp 1080:1080 jamesdbloom/mockserver:mockserver-5.13.2 -logLevel DEBUG -serverPort 1080
Metadata
Release files for helix-mockserver-client 2.0.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| helix_mockserver_client-2.0.7.tar.gz | 30.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| helix_mockserver_client-2.0.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 74.4 kB
Release files / helix_mockserver_client-2.0.7.tar.gz
| Download URL | helix_mockserver_client-2.0.7.tar.gz |
|---|---|
| Size | 30.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f87f5c87a60e750d32c637bf9041e6718e922a09a40fbe89f7c25ea06b32341d
|
|
BLAKE2b-256 checksum How to use checksums |
28b52212df15436ccb6b79fb8a9f97c9e9804a47892e047bf85cdcc373239673
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.10
|
Release files / helix_mockserver_client-2.0.7-py3-none-any.whl
| Download URL | helix_mockserver_client-2.0.7-py3-none-any.whl |
|---|---|
| Size | 43.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7827e7f60d368b9ac5670f533661688a22d422bc104389e0754d26f80e43858d
|
|
BLAKE2b-256 checksum How to use checksums |
578e49174c5f7e4298256d3257e3aa57cd3603b04e751af610cdab7f2f72c4f5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.10
|