github.com/graywolf-at-work-2/terraform-vendor@v1.4.5/internal/command/testdata/plan-fail-condition/main.tf (about)

     1  locals {
     2    ami = "bar"
     3  }
     4  
     5  resource "test_instance" "foo" {
     6    ami = local.ami
     7  
     8    lifecycle {
     9      precondition {
    10        // failing condition
    11        condition = local.ami != "bar"
    12        error_message = "ami is bar"
    13      }
    14    }
    15  }