Archived
1
0

feat: добавил стандартный претестовый хук

This commit is contained in:
Egor Mikheev
2025-11-24 22:14:19 +03:00
parent 9d3fb6ae9a
commit 74513b4de3

View File

@ -0,0 +1,19 @@
import { beforeAll, afterAll } from 'bun:test';
import { redis } from '@/services/redis.service';
beforeAll(async () => {
console.log('Setting up test environment...');
try {
await redis.connect();
} catch (error) {
console.warn('Redis not available in tests, continuing without cache');
}
});
afterAll(async () => {
console.log('Cleaning up test environment...');
await redis.disconnect();
});