@@ -9,6 +9,7 @@ cmp docs/index.md expected-index.md
9
9
cmp docs/data-sources/example.md expected-datasource.md
10
10
cmp docs/resources/example.md expected-resource.md
11
11
cmp docs/functions/example.md expected-function.md
12
+ cmp docs/functions/no-variadic.md expected-no-variadic-function.md
12
13
cmp docs/ephemeral-resources/example.md expected-ephemeral-resource.md
13
14
14
15
-- expected-output.txt --
@@ -22,6 +23,7 @@ generating missing data source content
22
23
generating new template for data-source "scaffolding_example"
23
24
generating missing function content
24
25
generating new template for function "example"
26
+ generating new template for function "no-variadic"
25
27
generating missing ephemeral resource content
26
28
generating new template for "scaffolding_example"
27
29
generating missing provider content
@@ -32,6 +34,7 @@ rendering templated website to static markdown
32
34
rendering "data-sources/example.md.tmpl"
33
35
rendering "ephemeral-resources/example.md.tmpl"
34
36
rendering "functions/example.md.tmpl"
37
+ rendering "functions/no-variadic.md.tmpl"
35
38
rendering "index.md.tmpl"
36
39
rendering "resources/example.md.tmpl"
37
40
-- expected-datasource.md --
@@ -99,6 +102,38 @@ example(input string, variadicInput string...) string
99
102
1. `input` (String) Value to echo.
100
103
<!-- variadic argument generated by tfplugindocs -->
101
104
1. `variadicInput` (Variadic, String) Variadic input to echo.
105
+ -- expected-no-variadic-function.md --
106
+ ---
107
+ # generated by https://github.com/hashicorp/terraform-plugin-docs
108
+ page_title: "no-variadic function - terraform-provider-scaffolding"
109
+ subcategory: ""
110
+ description: |-
111
+ Echo a string
112
+ ---
113
+
114
+ # function: no-variadic
115
+
116
+ Given a string value, returns the same value.
117
+
118
+ ## Example Usage
119
+
120
+ ```terraform
121
+ output "test" {
122
+ value = provider::scaffolding::no-variadic("testvalue1")
123
+ }
124
+ ```
125
+
126
+ ## Signature
127
+
128
+ <!-- signature generated by tfplugindocs -->
129
+ ```text
130
+ no-variadic(input string) string
131
+ ```
132
+
133
+ ## Arguments
134
+
135
+ <!-- arguments generated by tfplugindocs -->
136
+ 1. `input` (String) Value to echo.
102
137
-- expected-index.md --
103
138
---
104
139
# generated by https://github.com/hashicorp/terraform-plugin-docs
@@ -207,6 +242,10 @@ data "scaffolding_example" "example" {
207
242
output "test" {
208
243
value = provider::scaffolding::example("testvalue1", "testvalue2")
209
244
}
245
+ -- examples/functions/no-variadic/function.tf --
246
+ output "test" {
247
+ value = provider::scaffolding::no-variadic("testvalue1")
248
+ }
210
249
-- examples/provider/provider.tf --
211
250
provider "scaffolding" {
212
251
# example configuration here
@@ -340,6 +379,18 @@ resource "scaffolding_example" "example" {
340
379
"description": "Variadic input to echo.",
341
380
"type": "string"
342
381
}
382
+ },
383
+ "no-variadic": {
384
+ "description": "Given a string value, returns the same value.",
385
+ "summary": "Echo a string",
386
+ "return_type": "string",
387
+ "parameters": [
388
+ {
389
+ "name": "input",
390
+ "description": "Value to echo.",
391
+ "type": "string"
392
+ }
393
+ ]
343
394
}
344
395
}
345
396
}
0 commit comments