ci: expand shared package validation and test coverage
Lint / Lint (push) Successful in 32s
Docker / Docker Build & Push (push) Failing after 2m22s
Tests / Go backend (push) Failing after 1m2s
Tests / Dashboard checks (push) Failing after 35s

- Add lint, formatting, vet, and publish workflow checks
- Run Go database tests with PostgreSQL and add Java tests
- Make consumer sync opt-in; update docs and Go dependency
This commit is contained in:
Gabriel20xx committed 2026-10-19 21:46:52 +00:00
1 parent 937f51b4fb
commit 0ff94f9b10
107 files changed
+10124 -410

No files matched your search

@@ -6,21 +6,18 @@ import { fileURLToPath } from 'node:url';
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const repoRoot = path.resolve(__dirname, '..', '..');
// The monorepo kept its canonical JS/TS test sources under a single repo-root tests/ dir, which
// doesn't exist in this repo. Scan the real locations JS/TS test files can currently live in
// this repo instead: webui/src (SvelteKit app) and shared/packages/*/test(s) (vendored from the
// shared repo). repoRoot/tests is kept as a forward-compatible root in case one is added later.
// As of this repo's extraction, none of these contain vitest/mocha/jest-style test files yet
// (shared/packages/node-backend/test/auth.test.js uses plain `node --test`, which shares the same
// describe/it/test .skip API surface these patterns already match), so this currently passes
// trivially rather than being a dead check.
// Scan the JS/TS test locations that exist in this repo: the web-ui tests (packages/web-ui/tests,
// plus anything under its source) and the Node package's test directory. repoRoot/tests is kept as a
// forward-compatible root. A scan that finds no test files fails, so the check cannot pass
// vacuously.
const testsRoots = [
path.join(repoRoot, 'tests'),
path.join(repoRoot, 'webui', 'src'),
path.join(repoRoot, 'shared', 'packages'),
path.join(repoRoot, 'packages', 'web-ui', 'src'),
path.join(repoRoot, 'packages', 'web-ui', 'tests'),
path.join(repoRoot, 'packages', 'node-backend', 'test'),
];
const TEST_FILE_EXTENSIONS = new Set(['.js', '.mjs', '.cjs']);
const TEST_FILE_EXTENSIONS = new Set(['.js', '.mjs', '.cjs', '.ts']);
const DISALLOWED_LINE_PATTERNS = [
{
name: 'skip/todo/runIf declaration',
@@ -79,6 +76,10 @@ function collectViolations(filePath) {
}
const files = testsRoots.flatMap(listTestFiles).sort();
if (files.length === 0) {
console.error('[enforce-no-skipped-tests] No test files were found in the scanned roots; refusing to report success.');
process.exit(1);
}
const failures = [];
for (const filePath of files) {