-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test and update timeout for endpoint
- Loading branch information
Showing
4 changed files
with
36 additions
and
7 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { beforeAll, describe, expect, it } from "bun:test"; | ||
import { treaty } from "@elysiajs/eden"; | ||
import Elysia from "elysia"; | ||
import { healthApi } from "./api"; | ||
|
||
describe("health", () => { | ||
const app = new Elysia().use(healthApi); | ||
const api = treaty(app); | ||
|
||
it("should return 200 for /health", async () => { | ||
const response = await api.health.get(); | ||
expect(response.status).toBe(200); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters