A pytest plugin to help with testing idem projects
Project description
A pytest plugin to help with testing idem projects
INSTALLATION
Install with pip:
pip install pytest-idem
DEVELOPMENT INSTALLATION
Clone the pytest-idem repo and install with pip:
git clone https://gitlab.com/vmware/idem/pytest-idem.git pip install -e pytest-idem
ACCT
Some projects, specifically need credentials from idem’s ctx generator. A ctx fixture exists, but it won’t work unless you override the acct_file and acct_profile fixtures:
@pytest.fixture def acct_subs() -> List[str]: return ["azurerm", "vultr"] @pytest.fixture def acct_profile() -> str: return "test_development_idem_cloud"
Once these fixtures are overridden, the ctx fixture will become available to your test:
test_cloud_instance_present(hub, ctx): hub.state.cloud.present(ctx, "instance_name")
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
pytest-idem-2.0.1.tar.gz
(10.6 kB
view details)
Built Distribution
File details
Details for the file pytest-idem-2.0.1.tar.gz
.
File metadata
- Download URL: pytest-idem-2.0.1.tar.gz
- Upload date:
- Size: 10.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.3 readme-renderer/35.0 requests/2.28.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.12.0 keyring/23.6.0 rfc3986/2.0.0 colorama/0.4.5 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 13b9c2c966816225f25138f735b7361d3be7250aa72bc55aa0ca58482e7a9ba2 |
|
MD5 | 0dcc1166c6549d4b8bcf432c4889b159 |
|
BLAKE2b-256 | b28e4be21e0998ea6b53ac067dcb2e1529a0024cee4cd90054a2ac65b1d1ad05 |
File details
Details for the file pytest_idem-2.0.1-py3-none-any.whl
.
File metadata
- Download URL: pytest_idem-2.0.1-py3-none-any.whl
- Upload date:
- Size: 10.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.3 readme-renderer/35.0 requests/2.28.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.12.0 keyring/23.6.0 rfc3986/2.0.0 colorama/0.4.5 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 67206597a5258f4ab9c162eef058d25e824652eb60865c7a240c8077043a2e2e |
|
MD5 | 4ba6a5f0da0ad36e6226b605a1a78b96 |
|
BLAKE2b-256 | b6303c3af22426a956d822f3212655986e10cc000a7989b6b0c47fdfcfbb0216 |