github.com/terramate-io/tf@v0.0.0-20230830114523-fce866b4dfcd/testing/equivalence-tests/tests/fully_populated_complex_destroy/main.tf (about)

     1  terraform {
     2    required_providers {
     3      tfcoremock = {
     4        source  = "hashicorp/tfcoremock"
     5        version = "0.1.1"
     6      }
     7    }
     8  }
     9  
    10  provider "tfcoremock" {}
    11  
    12  resource "tfcoremock_complex_resource" "complex" {
    13    id = "64564E36-BFCB-458B-9405-EBBF6A3CAC7A"
    14  
    15    number  = 987654321.0
    16    integer = 123456789
    17    float   = 123456789.0
    18  
    19    string = "a not very long or complex string"
    20  
    21    bool = true
    22  
    23    list = [
    24      {
    25        string = "this is my first entry in the list, and doesn't contain anything interesting"
    26      },
    27      {
    28        string = "this is my second entry in the list\nI am a bit more interesting\nand contain multiple lines\nbut I've been edited"
    29      },
    30      {
    31        string = "this is my third entry, and I actually have a nested list"
    32  
    33        list = [
    34          {
    35            number = 0
    36          },
    37          {
    38            number = 1
    39          },
    40          {
    41            number = 3
    42          },
    43          {
    44            number = 4
    45          }
    46        ]
    47      },
    48      {
    49        string = "this is my fourth entry, and I actually have a nested set and I edited my test"
    50  
    51        set = [
    52          {
    53            number = 0
    54          },
    55          {
    56            number = 2
    57          },
    58        ]
    59      }
    60    ]
    61  
    62    object = {
    63      string = "i am a nested object"
    64  
    65      number = 0
    66  
    67      object = {
    68        string = "i am a nested nested object"
    69        bool   = true
    70      }
    71    }
    72  
    73    map = {
    74      "key_one" = {
    75        string = "this is my first entry in the map, and doesn't contain anything interesting"
    76      },
    77      "key_two" = {
    78        string = "this is my second entry in the map\nI am a bit more interesting\nand contain multiple lines"
    79      },
    80      "key_three" = {
    81        string = "this is my third entry, and I actually have a nested list"
    82  
    83        list = [
    84          {
    85            number = 0
    86          },
    87          {
    88            number = 3
    89          },
    90          {
    91            number = 1
    92          },
    93          {
    94            number = 2
    95          }
    96        ]
    97      },
    98      "key_four" = {
    99        string = "this is my fourth entry, and I actually have a nested set"
   100  
   101        set = [
   102          {
   103            number = 0
   104          },
   105          {
   106            number = 1
   107          },
   108          {
   109            number = 3
   110          },
   111          {
   112            number = 4
   113          },
   114        ]
   115      }
   116    }
   117  
   118    set = [
   119      {
   120        string = "this is my first entry in the set, and doesn't contain anything interesting"
   121      },
   122      {
   123        string = "this is my second entry in the set\nI am a bit more interesting\nand contain multiple lines"
   124      },
   125      {
   126        string = "this is my third entry, and I actually have a nested list"
   127  
   128        list = [
   129          {
   130            number = 0
   131          },
   132          {
   133            number = 1
   134          },
   135          {
   136            number = 2
   137          }
   138        ]
   139      },
   140      {
   141        string = "this is my fourth entry, and I actually have a nested set"
   142  
   143        set = [
   144          {
   145            number = 0
   146          },
   147          {
   148            number = 1
   149          },
   150        ]
   151      }
   152    ]
   153  
   154    list_block {
   155      string = "{\"index\":0}"
   156    }
   157  
   158    list_block {
   159      string = "{\"index\":1}"
   160  
   161      list = [
   162        {
   163          number = 0
   164        },
   165        {
   166          number = 1
   167        },
   168        {
   169          number = 2
   170        }
   171      ]
   172    }
   173  
   174    set_block {
   175      string = "{\"index\":1}"
   176  
   177      list = [
   178        {
   179          number = 0
   180        },
   181        {
   182          number = 1
   183        },
   184        {
   185          number = 2
   186        }
   187      ]
   188    }
   189  
   190    set_block {
   191      string = "{\"index\":2}"
   192  
   193      set = [
   194        {
   195          number = 0
   196        },
   197        {
   198          number = 1
   199        },
   200      ]
   201    }
   202  
   203    set_block {
   204      string = "{\"index\":3}"
   205    }
   206  }