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-1.1.1.tar.gz
(9.9 kB
view details)
Built Distribution
File details
Details for the file pytest-idem-1.1.1.tar.gz
.
File metadata
- Download URL: pytest-idem-1.1.1.tar.gz
- Upload date:
- Size: 9.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/35.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 48611c162734a2c74694898196ab1f09ab80fe88a5e926a9eadcc310f72db050 |
|
MD5 | c8b21865c6da9422b3dd0bccb3f532ef |
|
BLAKE2b-256 | 479b2ba8fc6ce20f44583deaf38feb4a7682f0c2d6fc156ebeabe38bdde009fc |
File details
Details for the file pytest_idem-1.1.1-py3-none-any.whl
.
File metadata
- Download URL: pytest_idem-1.1.1-py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/35.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 32f0c40485b76c1c09ae6334956ef951fc9f629c9ea6d1a0c4ebb92ff97a7cd5 |
|
MD5 | c8d10f24f680771f83901e66a5e8c38d |
|
BLAKE2b-256 | e629213205db2178f394a88d36b5f89cfac25839e6bb6c00d369b94054812524 |