feat(e2e): Add configurable timeout for go test execution within scenarios (#3213)

This commit is contained in:
Josh Brand authored and GitHub committed 2023-05-09 14:55:19 -04:00
1 parent 736cde3584
commit 5ac29eb2e5
4 files changed
+16 -2

No files matched your search

+5 -1
View File
@@ -116,6 +116,10 @@ variable "worker_tags" {
type = list(string)
default = [""]
}
variable "test_timeout" {
type = string
default = "10m"
}
locals {
aws_ssh_private_key_path = abspath(var.aws_ssh_private_key_path)
@@ -149,7 +153,7 @@ resource "enos_local_exec" "run_e2e_test" {
E2E_WORKER_TAG = jsonencode(var.worker_tags),
}
inline = var.debug_no_run ? [""] : ["set -o pipefail; PATH=\"${var.local_boundary_dir}:$PATH\" go test -v ${var.test_package} -count=1 -json | tparse -follow -format plain 2>&1 | tee ${path.module}/../../test-e2e-${local.package_name}.log"]
inline = var.debug_no_run ? [""] : ["set -o pipefail; PATH=\"${var.local_boundary_dir}:$PATH\" go test -v ${var.test_package} -count=1 -json -timeout ${var.test_timeout}| tparse -follow -format plain 2>&1 | tee ${path.module}/../../test-e2e-${local.package_name}.log"]
}
output "test_results" {