Skip to main content

An In-Memory Stub for Google Cloud Datastore

This project is a pure python implementation of the Google Cloud Datastore RPC Spec. This allows projects using the python-ndb lirary to write unit tests without needing to depend on/manage the full datastore emulator.

Installing

InMemoryCloudDatatoreStub can be installed from PyPi:

$ pip install InMemoryCloudDatastoreStub

Using

The stub can be inserted into your unit tests as a pytest fixture using monkeypatch:

from unittest.mock import magicMock

import pytest
from InMemoryCloudDatastoreStub.datastore_stub import LocalDatastoreStub

@pytest.fixture()
def ndb_stub(monkeypatch):
    stub = LocalDatastoreStub()
    monkeypatch.setattr(_datastore_api, "stub", MagicMock(return_value=stub))
    return stub

Metadata

Release files for InMemoryCloudDatastoreStub 0.0.15

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for InMemoryCloudDatastoreStub 0.0.15
File Size Uploaded Provenance Actions
InMemoryCloudDatastoreStub-0.0.15.tar.gz 8.4 kB Without provenance Details for InMemoryCloudDatastoreStub-0.0.15.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for InMemoryCloudDatastoreStub 0.0.15
File Interpreter ABI Platform Actions
InMemoryCloudDatastoreStub-0.0.15-py3-none-any.whl Python 3 none any Details for InMemoryCloudDatastoreStub-0.0.15-py3-none-any.whl

Total release size: 20.6 kB

Release files / InMemoryCloudDatastoreStub-0.0.15.tar.gz

Download URL InMemoryCloudDatastoreStub-0.0.15.tar.gz
Size 8.4 kB
Tags Source
SHA-256 checksum
How to use checksums
9ee24d86795749b020e827565bcbbbac60c3774ec5bcb351b6c4dfcd4061edb1
BLAKE2b-256 checksum
How to use checksums
dba2e9fd99c853154ee0688d17be3e7cb53fc8958ff08fc21d40b5c80d7f68fe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.7

Release files / InMemoryCloudDatastoreStub-0.0.15-py3-none-any.whl

Download URL InMemoryCloudDatastoreStub-0.0.15-py3-none-any.whl
Size 12.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b92b687fb2d4605cec5b63479e86fbd6697576950bad4469c696b2532cb04864
BLAKE2b-256 checksum
How to use checksums
9ab9300dd528e97a4378e3b17683f4f519a92da592bedf8f84c2a66ee92dd06c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.7

Security for InMemoryCloudDatastoreStub 0.0.15

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page