Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| db0963a7db |
@@ -1,15 +0,0 @@
|
||||
import { describe, it, expect } from 'vitest';
|
||||
import fs from 'node:fs';
|
||||
import path from 'node:path';
|
||||
|
||||
describe('Docker Configuration Project Name Integrity', () => {
|
||||
it('ensures docker-compose.yml has no legacy klz project fallbacks', () => {
|
||||
const composeContent = fs.readFileSync(path.resolve(process.cwd(), 'docker-compose.yml'), 'utf-8');
|
||||
expect(composeContent).not.toContain('klz');
|
||||
});
|
||||
|
||||
it('ensures docker-compose.dev.yml has no legacy klz project fallbacks', () => {
|
||||
const devComposeContent = fs.readFileSync(path.resolve(process.cwd(), 'docker-compose.dev.yml'), 'utf-8');
|
||||
expect(devComposeContent).not.toContain('klz');
|
||||
});
|
||||
});
|
||||
@@ -1,21 +0,0 @@
|
||||
import { describe, it, expect } from 'vitest';
|
||||
import { config } from '../proxy';
|
||||
|
||||
describe('Proxy Middleware Config Matcher', () => {
|
||||
const matcherRegex = new RegExp(`^${config.matcher[0]}`);
|
||||
|
||||
|
||||
it('matches localized page routes for next-intl processing', () => {
|
||||
expect(matcherRegex.test('/de')).toBe(true);
|
||||
expect(matcherRegex.test('/en/contact')).toBe(true);
|
||||
expect(matcherRegex.test('/karriere')).toBe(true);
|
||||
});
|
||||
|
||||
it('excludes static assets with any file extension including uppercase .JPG and subdirectories', () => {
|
||||
// These should NOT match the middleware (expect test to be false so middleware is bypassed)
|
||||
expect(matcherRegex.test('/assets/photos/DJI_0048.JPG')).toBe(false);
|
||||
expect(matcherRegex.test('/assets/videos/web/hero-kabelpflug-poster.jpg')).toBe(false);
|
||||
expect(matcherRegex.test('/assets/logo-white.png')).toBe(false);
|
||||
expect(matcherRegex.test('/_next/image')).toBe(false);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user