Library for mocking AsyncIOMotorClient built on top of mongomock.
Project description
mongomock-motor
Best effort mock for AsyncIOMotorClient (Database, Collection, e.t.c) built on top of mongomock library.
Example / Showcase
from mongomock_motor import AsyncMongoMockClient
async def test_mock_client():
collection = AsyncMongoMockClient()['tests']['test-1']
assert await collection.find({}).to_list(None) == []
result = await collection.insert_one({'a': 1})
assert result.inserted_id
assert len(await collection.find({}).to_list(None)) == 1
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mongomock_motor-0.0.6.tar.gz
(4.2 kB
view details)
Built Distributions
mongomock_motor-0.0.6-py3.8.egg
(12.5 kB
view details)
File details
Details for the file mongomock_motor-0.0.6.tar.gz
.
File metadata
- Download URL: mongomock_motor-0.0.6.tar.gz
- Upload date:
- Size: 4.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b42d8ed4c6bf435f54584a1570a1540d41ebe55fed1c614e490b3e9addeff499 |
|
MD5 | cdcc24f92ca5aaf9aafd9700f6334302 |
|
BLAKE2b-256 | c479fcf9e3e0ce06af7e7502fa580dda93b1bf3543ee28cb554b6659d7482574 |
Provenance
File details
Details for the file mongomock_motor-0.0.6-py3.8.egg
.
File metadata
- Download URL: mongomock_motor-0.0.6-py3.8.egg
- Upload date:
- Size: 12.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fca44355ee2d14be847d2058ce49c17973bc20ff7ccf87c0810f973bd8b08f17 |
|
MD5 | 75dfdd0afae7975af361050d88bad743 |
|
BLAKE2b-256 | df02c79574a9eec0ca31f4763e4863ea0a681a649535e43d76bad6604ecc9a19 |
Provenance
File details
Details for the file mongomock_motor-0.0.6-py3-none-any.whl
.
File metadata
- Download URL: mongomock_motor-0.0.6-py3-none-any.whl
- Upload date:
- Size: 5.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0e94e75fb425b8a72ea451aa9627400eb079fc65ab602f3d9b5c10e71bb1af95 |
|
MD5 | ef896557e6eab95ef5ca6d207e05840a |
|
BLAKE2b-256 | a02c1fd86ad7839cbc7197d2848159d37645c28d9fd2f1b0aeadc1d7a1324ec1 |