IKHSAN
EN Read in EnglishID

homeio

Publik

Fork dari doctor-io/homeio

Branch
main
Commit terakhir
958d74616 Oktober 2026

route.test.ts

Buka raw
import { describe, expect, it } from "vitest";
import { GET } from "@/app/api/health/route";

describe("GET /api/health", () => {
  it("returns healthy status payload", async () => {
    const response = await GET();
    const json = (await response.json()) as {
      ok: boolean;
      service: string;
      timestamp: string;
    };

    expect(response.status).toBe(200);
    expect(json.ok).toBe(true);
    expect(json.service).toBe("home-server");
    expect(json.timestamp).toBeTypeOf("string");
  });
});
byte
514
baris
19
Jenis
ts
Commit terakhir
16 Oktober 2026