Skip to content
This repository was archived by the owner on Dec 8, 2025. It is now read-only.

Commit 8507f29

Browse files
committed
chore: improve testdata
1 parent 24c0ca9 commit 8507f29

File tree

5 files changed

+21
-4
lines changed

5 files changed

+21
-4
lines changed

pkg/overlay/testdata/openapi-overlayed.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,15 @@ paths:
106106
/drinks:
107107
x-speakeasy-note:
108108
"$ref": "./removeNote.yaml"
109-
/drink/{name}: #TODO: this should be by product code and we should have search by name
109+
/drink/{name}: # Example comment -- should be maintained
110110
get:
111111
operationId: getDrink
112112
summary: Get a drink.
113-
description: Get a drink by name, if authenticated this will include stock levels and product codes otherwise it will only include public information.
113+
description: |
114+
A long description
115+
to validate that we handle indentation properly
116+
117+
With a second paragraph
114118
tags:
115119
- drinks
116120
parameters:

pkg/overlay/testdata/openapi-strict-onechange.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ paths:
128128
$ref: "#/components/responses/APIError"
129129
default:
130130
$ref: "#/components/responses/UnknownError"
131-
/drink/{name}: #TODO: this should be by product code and we should have search by name
131+
/drink/{name}: # Example comment -- should be maintained
132132
get:
133133
operationId: getDrink
134134
summary: Get a drink.

pkg/overlay/testdata/openapi.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ paths:
131131
default:
132132
$ref: "#/components/responses/UnknownError"
133133

134-
/drink/{name}: #TODO: this should be by product code and we should have search by name
134+
/drink/{name}: # Example comment -- should be maintained
135135
get:
136136
operationId: getDrink
137137
summary: Get a drink.

pkg/overlay/testdata/overlay-generated.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,12 @@ actions:
1818
"$ref": "./removeNote.yaml"
1919
- target: $["paths"]["/drinks"]["get"]
2020
remove: true
21+
- target: $["paths"]["/drink/{name}"]["get"]["description"]
22+
update: |
23+
A long description
24+
to validate that we handle indentation properly
25+
26+
With a second paragraph
2127
- target: $["paths"]["/drink/{name}"]["get"]["parameters"]
2228
update:
2329
- x-parameter-extension: foo

pkg/overlay/testdata/overlay.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,11 @@ actions:
4040
servers:
4141
- url: http://localhost:35123
4242
description: The default server.
43+
- target: $.paths["/drink/{name}"].get
44+
update:
45+
description: |
46+
A long description
47+
to validate that we handle indentation properly
48+
49+
With a second paragraph
4350
x-top-level-extension: true

0 commit comments

Comments
 (0)