Skip to content

Commit

Permalink
Fix: Workflow environment creation integration test (#647)
Browse files Browse the repository at this point in the history
* fix environment integration test

* use another template for tests

* remove second sub env from tf file

* remove workspace from subenv
  • Loading branch information
Yossi-kerner committed May 8, 2023
1 parent bbebd7b commit 57b174c
Showing 1 changed file with 7 additions and 20 deletions.
27 changes: 7 additions & 20 deletions tests/integration/012_environment/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ resource "env0_template" "workflow_template" {
name = "Template for workflow environment-${random_string.random.result}"
type = "workflow"
repository = "https://github.com/env0/templates"
path = "misc/workflow-environment-basic"
path = "misc/single-environment-workflow"
terraform_version = "1.1.5"
}

Expand All @@ -154,28 +154,15 @@ resource "env0_environment" "workflow-environment" {
approve_plan_automatically = true

sub_environment_configuration {
alias = "rootService1"
revision = "master"
alias = "rootService1"
revision = "master"
configuration {
name = "sub_env1_var1"
value = "hello"
name = "sub_env1_var1"
value = "hello"
}
configuration {
name = "sub_env1_var2"
value = "world"
}
}

sub_environment_configuration {
alias = "rootService2"
revision = "master"
configuration {
name = "sub_env2_var1"
value = "hello"
}
configuration {
name = var.second_run ? "sub_env2_var3" : "sub_env2_var2"
value = var.second_run ? "world2" : "world"
name = "sub_env1_var2"
value = "world"
}
}
}

0 comments on commit 57b174c

Please sign in to comment.