Full tests coverage

This commit is contained in:
Aerilyn Weber 2026-05-19 14:09:03 +09:00
parent 99134d8556
commit 02d782c3da
157 changed files with 1074 additions and 34670 deletions

View file

@ -0,0 +1,19 @@
import { vi, describe, it, expect } from 'vitest';
// Mock the auth module to prevent loading NextAuth server-side runtime dependencies
vi.mock('@/lib/auth', () => {
return {
auth: vi.fn(),
};
});
import { proxy, config } from '../src/proxy';
describe('middleware proxy configuration', () => {
it('exports proxy and route matcher configurations successfully', () => {
expect(proxy).toBeDefined();
expect(config).toBeDefined();
expect(config.matcher).toBeDefined();
expect(config.matcher[0]).toContain('api/auth');
});
});