@@ -9,6 +9,7 @@ cmp docs/index.md expected-index.md
99cmp docs/data-sources/example.md expected-datasource.md
1010cmp docs/resources/example.md expected-resource.md
1111cmp docs/functions/example.md expected-function.md
12+ cmp docs/functions/no-variadic.md expected-no-variadic-function.md
1213cmp docs/ephemeral-resources/example.md expected-ephemeral-resource.md
1314
1415-- expected-output.txt --
@@ -22,6 +23,7 @@ generating missing data source content
2223generating new template for data-source "scaffolding_example"
2324generating missing function content
2425generating new template for function "example"
26+ generating new template for function "no-variadic"
2527generating missing ephemeral resource content
2628generating new template for "scaffolding_example"
2729generating missing provider content
@@ -32,6 +34,7 @@ rendering templated website to static markdown
3234rendering "data-sources/example.md.tmpl"
3335rendering "ephemeral-resources/example.md.tmpl"
3436rendering "functions/example.md.tmpl"
37+ rendering "functions/no-variadic.md.tmpl"
3538rendering "index.md.tmpl"
3639rendering "resources/example.md.tmpl"
3740-- expected-datasource.md --
@@ -99,11 +102,42 @@ example(input string, variadicInput string...) string
991021. `input` (String) Value to echo.
100103<!-- variadic argument generated by tfplugindocs -->
1011041. `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.
102137-- expected-index.md --
103138---
104139# generated by https://github.com/hashicorp/terraform-plugin-docs
105140page_title: "Scaffolding Provider"
106- subcategory: ""
107141description: |-
108142 Example provider
109143---
@@ -208,6 +242,10 @@ data "scaffolding_example" "example" {
208242output "test" {
209243 value = provider::scaffolding::example("testvalue1", "testvalue2")
210244}
245+ -- examples/functions/no-variadic/function.tf --
246+ output "test" {
247+ value = provider::scaffolding::no-variadic("testvalue1")
248+ }
211249-- examples/provider/provider.tf --
212250provider "scaffolding" {
213251 # example configuration here
@@ -341,6 +379,18 @@ resource "scaffolding_example" "example" {
341379 "description": "Variadic input to echo.",
342380 "type": "string"
343381 }
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+ ]
344394 }
345395 }
346396 }
0 commit comments