mirror of
https://github.com/Infisical/infisical.git
synced 2026-05-02 03:02:03 -04:00
22 lines
489 B
TypeScript
22 lines
489 B
TypeScript
import { Server } from "http";
|
|
import main from "../src";
|
|
import { afterAll, beforeAll, describe, expect, it } from "@jest/globals";
|
|
import request from "supertest";
|
|
|
|
let server: Server;
|
|
|
|
beforeAll(async () => {
|
|
server = await main;
|
|
});
|
|
|
|
afterAll(async () => {
|
|
server.close();
|
|
});
|
|
|
|
describe("Healthcheck endpoint", () => {
|
|
it("GET /healthcheck should return OK", async () => {
|
|
const res = await request(server).get("/healthcheck");
|
|
expect(res.status).toEqual(200);
|
|
});
|
|
});
|