backend/src/tests/firsttest.spec.ts

15 lines
411 B
TypeScript

import axios from 'axios';
describe('GET /api/openapi.json', () => {
it('is http 200', async () => {
const res = await axios.get('http://localhost:4010/api/openapi.json');
expect(res.status).toEqual(200);
});
});
describe('GET /', () => {
it('is http 404', async () => {
const res = await axios.get('http://localhost:4010/', { validateStatus: undefined });
expect(res.status).toEqual(404);
});
});