e1773481e2
- Add allowDefaultProject for JS config files in eslint.config.mjs - Add no-console: off for test setup files - Fix async arrow function without await in jest-e2e.setup.ts - Remove unused eslint-disable directives
27 lines
596 B
TypeScript
27 lines
596 B
TypeScript
/**
|
|
* Jest E2E Test Setup
|
|
*
|
|
* Global configuration สำหรับ E2E tests
|
|
* @see specs/05-Engineering-Guidelines/05-04-testing-strategy.md
|
|
*/
|
|
|
|
import 'reflect-metadata';
|
|
|
|
// E2E tests ใช้เวลานานกว่า unit tests
|
|
jest.setTimeout(60000);
|
|
|
|
// Global beforeAll - สามารถใช้ setup database connection ที่นี่
|
|
beforeAll(async () => {
|
|
// E2E specific setup
|
|
});
|
|
|
|
// Global afterAll - cleanup
|
|
afterAll(async () => {
|
|
// E2E specific cleanup
|
|
});
|
|
|
|
// Clean up หลังแต่ละ test
|
|
afterEach(() => {
|
|
jest.clearAllMocks();
|
|
});
|