Skip to content

Commit

Permalink
Change to string comparision in Terratests
Browse files Browse the repository at this point in the history
  • Loading branch information
lgallard committed Oct 25, 2021
1 parent 5591eb6 commit f7e012c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tests/fixture/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
#
output "budget_sns_topic_arn" {
description = "List of SNS Topic ARNs to be subscribed to in order to delivery the budget billing notifications"
value = module.billing_cloudwatch_alert.sns_topic_arns
value = module.billing_cloudwatch_alert.sns_topic_arns[0]
}
4 changes: 2 additions & 2 deletions tests/verify_output_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
)

func TestAWSBudget(t *testing.T) {
expectedBudgetSnsTopicArn := []string{"arn:aws:sns:us-east-1:523857393444:billing-alarm-notification-usd-bb-dev-deploymaster"}
expectedBudgetSnsTopicArn := "arn:aws:sns:us-east-1:523857393444:billing-alarm-notification-usd-bb-dev-deploymaster"

terraformOptions := &terraform.Options {
// The path to where our Terraform code is located
Expand All @@ -25,7 +25,7 @@ func TestAWSBudget(t *testing.T) {
terraform.InitAndApply(t, terraformOptions)

// Run `terraform output` to get the values of output variables
actualBudgetSnsTopicArn := terraform.OutputList(t, terraformOptions, "budget_sns_topic_arn")
actualBudgetSnsTopicArn := terraform.Output(t, terraformOptions, "budget_sns_topic_arn")


// Verify we're getting back the outputs we expect
Expand Down

0 comments on commit f7e012c

Please sign in to comment.