Skip to content

Commit

Permalink
Test response_key
Browse files Browse the repository at this point in the history
  • Loading branch information
andrii-balitskyi committed Jul 11, 2024
1 parent 838ca41 commit 3eacc4c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions apps/example-todo-app/pages/api/todo/add.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export const route_spec = checkRouteSpec({
description: `
---
deprecated: Use foobar instead.
response_key: foobar
---
This endpoint allows you to add a new todo item to the list. Deprecated.
`,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,6 @@ test("generateOpenAPI correctly parses description with front matter", async (t)
"This endpoint allows you to add a new todo item to the list. Deprecated."
)
t.is(routeSpec.deprecated, "Use foobar instead.")
t.is(routeSpec["x-fern-sdk-return-value"], "foobar")
t.is(routeSpec.response_key, "foobar")
})

0 comments on commit 3eacc4c

Please sign in to comment.