learning_ai_common_plat/packages/devops/src/__tests__
root 51fc8d09b0
Some checks are pending
CI — Common Platform / Build, Test & Typecheck (push) Waiting to run
CI — Common Platform / Publish @bytelyst/* to Gitea npm registry (push) Blocked by required conditions
feat(devops): admin-only collector helpers, public version, deps + tests
Bumps @bytelyst/devops to 0.1.2.

Adds:
- getBuildInfo() — public-safe build info (commit + branch + image),
  no env vars or runtime introspection. Suitable for unauthenticated
  /api/devops/version endpoints used by ops/CI.
- getRuntimeInfo() / getConfigInfo() — exposed individually for callers
  who want to compose their own payload.
- readServiceVersion(import.meta.url) — walks up to package.json so
  consumers don't need to hardcode the version string.
- dependencyCheck(name, fn, timeoutMs) — timed health check wrapper
  with consistent ok/latency/detail shape. Enforces a hard timeout.
- httpDependencyCheck(name, url, timeoutMs) — convenience for HTTP probes.

Other improvements:
- SECRET_PATTERN extracted as a module constant.
- 17 unit tests covering build/runtime/config collectors, secret-leak
  guards, version walker fallbacks, dep timeouts, full collect payload.

Generated with [Devin](https://cli.devin.ai/docs)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-05-10 05:52:21 +00:00
..
server.test.ts feat(devops): admin-only collector helpers, public version, deps + tests 2026-05-10 05:52:21 +00:00