Skip to content

Commit 20efc73

Browse files
committed
test: custom content for responses
1 parent 8ba3780 commit 20efc73

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

src/core/responses.test.ts

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,4 +89,34 @@ describe("bundleResponses", () => {
8989
},
9090
});
9191
});
92+
93+
it("should handle custom content", () => {
94+
const result = bundleResponses({
95+
200: {
96+
description: "Success",
97+
customContent: {
98+
"application/vnd.openxmlformats-officedocument.presentationml.presentation": {
99+
schema: {
100+
type: "string",
101+
format: "binary",
102+
},
103+
},
104+
},
105+
},
106+
});
107+
108+
expect(result).toEqual({
109+
200: {
110+
description: "Success",
111+
content: {
112+
"application/vnd.openxmlformats-officedocument.presentationml.presentation": {
113+
schema: {
114+
type: "string",
115+
format: "binary",
116+
},
117+
},
118+
},
119+
},
120+
});
121+
});
92122
});

0 commit comments

Comments
 (0)