Update tests
This commit is contained in:
parent
a0dbb79d30
commit
872b29179e
1 changed files with 13 additions and 1 deletions
|
@ -78,6 +78,7 @@ def test_should_calculate_project_vars():
|
||||||
{
|
{
|
||||||
"do_as_backend": False,
|
"do_as_backend": False,
|
||||||
"aws_as_backend": False,
|
"aws_as_backend": False,
|
||||||
|
"tf_provider_types": ["DIGITALOCEAN", "HETZNER", "AWS"]
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
sut = TerraformDomain(config)
|
sut = TerraformDomain(config)
|
||||||
|
@ -167,6 +168,17 @@ def test_should_calculate_resources_from_package():
|
||||||
"aws_provider_vars.tf",
|
"aws_provider_vars.tf",
|
||||||
"aws_backend_wkms_vars.tf",
|
"aws_backend_wkms_vars.tf",
|
||||||
"my.file",
|
"my.file",
|
||||||
|
"tf_backend_git_backend_vars.tf",
|
||||||
|
"tf_backend_git_backend.tf",
|
||||||
|
} == sut.resources_from_package()
|
||||||
|
|
||||||
|
config = devops_config({"tf_provider_types": ["TERRAFORM_BACKEND_GIT"]})
|
||||||
|
sut = TerraformDomain(config)
|
||||||
|
assert {
|
||||||
|
"versions.tf",
|
||||||
|
"terraform_build_vars.tf",
|
||||||
|
"tf_backend_git_backend_vars.tf",
|
||||||
|
"tf_backend_git_backend.tf",
|
||||||
} == sut.resources_from_package()
|
} == sut.resources_from_package()
|
||||||
|
|
||||||
|
|
||||||
|
@ -192,4 +204,4 @@ def test_should_calculate_local_state_handling():
|
||||||
|
|
||||||
def test_should_use_backend_git():
|
def test_should_use_backend_git():
|
||||||
sut = TerraformDomain(devops_config({}))
|
sut = TerraformDomain(devops_config({}))
|
||||||
assert TerraformDomain.uses_backend_git()
|
assert sut.uses_backend_git()
|
Loading…
Reference in a new issue