Skip to content

Commit ceec9bd

Browse files
chore(core): updated the tests
1 parent ffc9909 commit ceec9bd

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

packages/core/src/__tests__/basic.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ describe("basic", async () => {
3838
.post(
3939
"/documents",
4040
registerResources((c) => {
41-
return c.json([
41+
return [
4242
{
4343
uri: "https://lorem.ipsum",
4444
name: "Todo list",
@@ -50,7 +50,7 @@ describe("basic", async () => {
5050
name: "Todo list",
5151
mimeType: "text/plain",
5252
},
53-
]);
53+
];
5454
}),
5555
)
5656
.post(

packages/core/src/__tests__/resources.test.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ describe("resources", async () => {
1414

1515
const app = new Hono().post(
1616
"/",
17-
registerResources((c) => {
18-
return c.json<Resource[]>([resource]);
17+
registerResources(() => {
18+
return [resource];
1919
}),
2020
);
2121

@@ -86,8 +86,8 @@ describe("resources", async () => {
8686

8787
const app = new Hono().post(
8888
"/",
89-
registerResources((c) => {
90-
return c.json<Resource[]>([resource]);
89+
registerResources(() => {
90+
return [resource];
9191
}),
9292
);
9393

@@ -171,8 +171,8 @@ describe("resources", async () => {
171171

172172
const app = new Hono().post(
173173
"/",
174-
registerResources((c) => {
175-
return c.json<Resource[]>(mixedResources);
174+
registerResources(() => {
175+
return mixedResources;
176176
}),
177177
);
178178

0 commit comments

Comments
 (0)