fix(backend): resolve ESLint errors for Jest config and test setup files
- 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
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
/**
|
||||
* 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();
|
||||
});
|
||||
Reference in New Issue
Block a user