test: harden package boundaries and audit budgets
Quality / quality (windows-latest) (push) Waiting to run
Quality / quality (ubuntu-latest) (push) Failing after 9m52s

This commit is contained in:
2026-08-24 12:05:20 +05:30
parent 613ff7ae5b
commit b3c93e9b18
12 changed files with 115 additions and 17 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@wrnexus/dev-toolbar",
"version": "0.8.15",
"version": "0.8.16",
"private": true,
"type": "module",
"sideEffects": false,
@@ -23,3 +23,19 @@ test("server issues have stable fingerprints and retain actionable error context
expect(error.metadata?.stack).toContain("database offline");
expect(error.recommendation).toContain("stack trace");
});
test("non-Error throws are normalized without losing caller context", () => {
const issue = issueFromError(
{ reason: "offline" },
{
ruleId: "server/dependency",
title: "Dependency failed",
pathname: "/health",
source: { file: "app/api/health.ts", line: 4 },
},
);
expect(issue.ruleId).toBe("server/dependency");
expect(issue.title).toBe("Dependency failed");
expect(issue.message).toBe("[object Object]");
expect(issue.fingerprint).toContain("app/api/health.ts:4:0");
});