pytest插件,用于帮助测试idem项目
项目描述
pytest插件,用于帮助测试idem项目
安装
使用pip安装
pip install pytest-idem
开发安装
克隆pytest-idem仓库并使用pip安装
git clone https://gitlab.com/vmware/idem/pytest-idem.git pip install -e pytest-idem
ACCT
某些项目,特别是需要从idem的ctx生成器中获取凭证。存在一个ctx固定装置,但除非你覆盖了acct_file和acct_profile固定装置,否则它将不起作用
@pytest.fixture def acct_subs() -> List[str]: return ["azurerm", "vultr"] @pytest.fixture def acct_profile() -> str: return "test_development_idem_cloud"
一旦覆盖了这些固定装置,ctx固定装置将可用于你的测试
test_cloud_instance_present(hub, ctx): hub.state.cloud.present(ctx, "instance_name")
项目详情
下载文件
下载适合您平台的文件。如果您不确定选择哪个,请了解有关 安装包 的更多信息。
源分布
pytest-idem-4.0.1.tar.gz (11.9 kB 查看哈希值)
构建版本
pytest_idem-4.0.1-py3-none-any.whl (11.9 kB 查看哈希值)
关闭
pytest-idem-4.0.1.tar.gz 的哈希值
算法 | 哈希摘要 | |
---|---|---|
SHA256 | 70b986cb33814b4b7cad6bf35b2f36af8499ef6c0e3ff8f3c2fb78678d86819d |
|
MD5 | a9192ebbf8c4e11e70f977c3e3200810 |
|
BLAKE2b-256 | 4eb2ea776225f9487c5890cb88843d42e8ee2bf2329b154a3b2b95b273de7db1 |
关闭
pytest_idem-4.0.1-py3-none-any.whl 的哈希值
算法 | 哈希摘要 | |
---|---|---|
SHA256 | 18c0a3a6e4b04966f0bc964aec0b7b7b18224d6541c243ac960ebb3bfad54557 |
|
MD5 | 879452392279bd95aed2c40174883b64 |
|
BLAKE2b-256 | d281667c7ef41c8664be4b62e21fffa710b985c422af136501ce5e0b1e2ea890 |