mirror of
https://github.com/opentffoundation/opentf.git
synced 2026-01-21 08:00:49 -05:00
Also uncomment and fix some tests which had been skipped for a couple of years. Those validate cases work now! Note that these test cases and the JSON output are not especially minimized, making them snapshot/golden tests. The output looks correct at time of writing, and we don't expect to change validate significantly any time soon, but if we do there will be some churn here.
44 lines
1.6 KiB
JSON
44 lines
1.6 KiB
JSON
{
|
|
"valid": false,
|
|
"error_count": 1,
|
|
"warning_count": 1,
|
|
"diagnostics": [
|
|
{
|
|
"severity": "warning",
|
|
"summary": "Interpolation-only expressions are deprecated",
|
|
"detail": "Terraform 0.11 and earlier required all non-constant expressions to be provided via interpolation syntax, but this pattern is now deprecated. To silence this warning, remove the \"${ sequence from the start and the }\" sequence from the end of this expression, leaving just the inner expression.\n\nTemplate interpolation syntax is still used to construct strings from expressions when the template includes multiple interpolation sequences or a mixture of literal strings and interpolations. This deprecation applies only to templates that consist entirely of a single interpolation sequence.",
|
|
"range": {
|
|
"filename": "testdata/validate-invalid/missing_var/main.tf",
|
|
"start": {
|
|
"line": 6,
|
|
"column": 21,
|
|
"byte": 117
|
|
},
|
|
"end": {
|
|
"line": 6,
|
|
"column": 41,
|
|
"byte": 137
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"severity": "error",
|
|
"summary": "Reference to undeclared input variable",
|
|
"detail": "An input variable with the name \"description\" has not been declared. This variable can be declared with a variable \"description\" {} block.",
|
|
"range": {
|
|
"filename": "testdata/validate-invalid/missing_var/main.tf",
|
|
"start": {
|
|
"line": 6,
|
|
"column": 24,
|
|
"byte": 120
|
|
},
|
|
"end": {
|
|
"line": 6,
|
|
"column": 39,
|
|
"byte": 135
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|