From 872b29179ea6cd56fb1207d57c89f8c547570433 Mon Sep 17 00:00:00 2001 From: patdyn Date: Thu, 27 Jun 2024 14:19:19 +0200 Subject: [PATCH] Update tests --- src/test/python/domain/test_terraform.py | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/test/python/domain/test_terraform.py b/src/test/python/domain/test_terraform.py index b67486f..7c2a750 100644 --- a/src/test/python/domain/test_terraform.py +++ b/src/test/python/domain/test_terraform.py @@ -78,6 +78,7 @@ def test_should_calculate_project_vars(): { "do_as_backend": False, "aws_as_backend": False, + "tf_provider_types": ["DIGITALOCEAN", "HETZNER", "AWS"] } ) sut = TerraformDomain(config) @@ -167,6 +168,17 @@ def test_should_calculate_resources_from_package(): "aws_provider_vars.tf", "aws_backend_wkms_vars.tf", "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() @@ -192,4 +204,4 @@ def test_should_calculate_local_state_handling(): def test_should_use_backend_git(): sut = TerraformDomain(devops_config({})) - assert TerraformDomain.uses_backend_git() \ No newline at end of file + assert sut.uses_backend_git() \ No newline at end of file