Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Keep composed fixture checks on the current Vitest runner

pulse-triage[bot]6bdffafad378
diff --git a/frontend-modern/browser-tests/README.md b/frontend-modern/browser-tests/README.md
index ede73a925c..42992f1c1b 100644
--- a/frontend-modern/browser-tests/README.md
+++ b/frontend-modern/browser-tests/README.md
@@ -67,13 +67,10 @@ node browser-tests/build-publication-fixtures.mjs
npm run test -- browser-tests/publication-fixture-server.test.mjs
```
-The server regression uses Node's built-in test runner. Vitest excludes only
-that test body from discovery and awaits its standalone run through
-`src/__tests__/publicationFixtureServer.test.ts`. A Node failure still fails
-`npm test`; the command above also runs it independently. This preserves the
-binding, listener and cleanup checks without importing a Node suite as a
-Vitest file with no Vitest tests. The server checks exercise only a locally
-owned loopback listener and synthetic temporary files.
+The server regression uses Vitest's runner and is included in `npm test`.
+The command above also runs its binding, listener and cleanup checks on their
+own. The server checks exercise only a locally owned loopback listener and
+synthetic temporary files; no standalone Node bridge is needed.
The four corresponding browser runners use the resulting static bundles in
`tmp/publication-final-static` at the repository root. They no longer compile
diff --git a/frontend-modern/src/__tests__/publicationFixtureServer.test.ts b/frontend-modern/src/__tests__/publicationFixtureServer.test.ts
deleted file mode 100644
index 3df70f6ca3..0000000000
--- a/frontend-modern/src/__tests__/publicationFixtureServer.test.ts
+++ /dev/null
@@ -1,26 +0,0 @@
-import { execFile } from 'node:child_process';
-import path from 'node:path';
-import { fileURLToPath } from 'node:url';
-import { promisify } from 'node:util';
-import { expect, it } from 'vitest';
-
-const run = promisify(execFile);
-const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '../..');
-
-// Keep the server's existing node:test suite on its own runner, but make its
-// exit part of npm test. The suite owns its synthetic files, listener and
-// cleanup checks.
-it('passes the standalone publication fixture server suite', async () => {
- const { stdout, stderr } = await run(
- process.execPath,
- ['--test', '--test-reporter=tap', 'browser-tests/publication-fixture-server.test.cjs'],
- { cwd: root, timeout: 25000, maxBuffer: 1024 * 1024 },
- );
- expect(stdout).toContain('# fail 0');
- expect(stdout).toContain(
- 'serves only verified bytes, explicit routes and GET/HEAD; closes the listener',
- );
- // Retain the Node test count and outcomes beside the enclosing Vitest result.
- process.stdout.write(stdout);
- if (stderr) process.stderr.write(stderr);
-}, 30000);
diff --git a/frontend-modern/vite.config.ts b/frontend-modern/vite.config.ts
index f26a901720..e658f72fa8 100644
--- a/frontend-modern/vite.config.ts
+++ b/frontend-modern/vite.config.ts
@@ -291,10 +291,6 @@ export default defineConfig(({ mode }) => ({
...configDefaults.exclude,
'tests/integration/**',
'**/tests/integration/**',
- // Uses node:test, with its own loopback server and cleanup assertions.
- // The Vitest bridge awaits its node --test exit; README documents the
- // standalone command too. Do not discover the Node test body as Vitest.
- 'browser-tests/publication-fixture-server.test.cjs',
],
},
}));