ai-dev-template / nodejs /tests /unit /main.test.ts
Jordandevlog's picture
Upload nodejs/tests/unit/main.test.ts
a4bdccd verified
Raw
History Blame Contribute Delete
408 Bytes
/**
* Tests for main application.
* @module mainTests
*/
import { describe, it, expect } from 'vitest';
import request from 'supertest';
import { app } from '../../src/main';
describe('GET /health', () => {
it('should return status ok', async () => {
const response = await request(app).get('/health');
expect(response.status).toBe(200);
expect(response.body.status).toBe('ok');
});
});