github.com/kanishk98/terraform@v1.3.0-dev.0.20220917174235-661ca8088a6a/internal/refactoring/testdata/move-validate-zoo/move-validate-root.tf (about)

     1  
     2  # NOTE: This fixture is used in a test that doesn't run a full Terraform plan
     3  # operation, so the count and for_each expressions here can only be literal
     4  # values and mustn't include any references or function calls.
     5  
     6  module "single" {
     7    source = "./child"
     8  }
     9  
    10  module "count" {
    11    source = "./child"
    12    count  = 2
    13  }
    14  
    15  module "zero_count" {
    16    source = "./child"
    17    count  = 0
    18  }
    19  
    20  module "for_each" {
    21    source = "./child"
    22    for_each = {
    23      a = "A"
    24    }
    25  }
    26  
    27  resource "test" "single" {
    28  }
    29  
    30  resource "test" "count" {
    31    count = 2
    32  }
    33  
    34  resource "test" "zero_count" {
    35    count = 0
    36  }
    37  
    38  resource "test" "for_each" {
    39    for_each = {
    40      a = "A"
    41    }
    42  }
    43  
    44  resource "other" "single" {
    45  }
    46  
    47  module "fake_external" {
    48    # Our configuration fixture loader has a special case for a module call
    49    # named "fake_external" where it will mutate the source address after
    50    # loading to instead be an external address, so we can test rules relating
    51    # to crossing module boundaries.
    52    source = "./child"
    53  }