Security: Sync from Public / sync-from-public (push) Has been cancelled
Test: Benchmark Nightly / build (push) Has been cancelled
Test: Benchmark Nightly / Notify Cats on failure (push) Has been cancelled
CI: Python / Checks (push) Has been cancelled
Test: Evals Python / Workflow Comparison Python (push) Has been cancelled
Util: Check Docs URLs / check-docs-urls (push) Has been cancelled
Test: Visual Storybook / Cloudflare Pages (push) Has been cancelled
Test: E2E Performance / build-and-test-performance (push) Has been cancelled
Test: Workflows Nightly / Run Workflow Tests (push) Has been cancelled
Util: Cleanup CI Docker Images / Delete stale CI images (push) Has been cancelled
Test: Benchmark Destroy Env / build (push) Has been cancelled
Util: Update Node Popularity / update-popularity (push) Has been cancelled
Test: E2E Coverage Weekly / Coverage Tests (push) Has been cancelled
52 lines
1.5 KiB
TypeScript
52 lines
1.5 KiB
TypeScript
/**
|
|
* End-to-end UI test for log streaming feature.
|
|
*
|
|
* This test verifies:
|
|
* 1. Log streaming can be configured via the UI
|
|
* 2. Test events are streamed to VictoriaLogs via syslog
|
|
* 3. Events can be queried from VictoriaLogs
|
|
*/
|
|
|
|
import { test, expect } from '../../../../fixtures/base';
|
|
|
|
test.use({ capability: 'observability' });
|
|
|
|
test.describe('Log Streaming UI E2E @capability:observability', {
|
|
annotation: [
|
|
{ type: 'owner', description: 'Lifecycle & Governance' },
|
|
],
|
|
}, () => {
|
|
test.beforeEach(async ({ n8n }) => {
|
|
await n8n.api.enableFeature('logStreaming');
|
|
});
|
|
|
|
test('should configure syslog destination via UI and send test event', async ({
|
|
n8n,
|
|
services,
|
|
}) => {
|
|
const obs = services.observability;
|
|
|
|
// ========== STEP 1: Configure Log Streaming via UI ==========
|
|
await n8n.navigate.toLogStreaming();
|
|
await expect(n8n.settingsLogStreaming.getActionBoxLicensed()).toBeVisible();
|
|
|
|
// Create syslog destination pointing to VictoriaLogs
|
|
await n8n.settingsLogStreaming.createSyslogDestination({
|
|
name: 'VictoriaLogs E2E Test',
|
|
host: obs.syslog.host,
|
|
port: obs.syslog.port,
|
|
});
|
|
// Send test event
|
|
await n8n.settingsLogStreaming.sendTestEvent();
|
|
|
|
// ========== STEP 3: Verify Event in VictoriaLogs ==========
|
|
// Use wildcard search - LogsQL interprets dots as word separators
|
|
const testEvent = await obs.logs.waitForLog('*destination.test*', {
|
|
timeoutMs: 30000,
|
|
start: '-2m',
|
|
});
|
|
|
|
expect(testEvent).toBeTruthy();
|
|
});
|
|
});
|