@orangecheck/agent-signer 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@orangecheck/agent-signer",
3
- "version": "0.3.0",
3
+ "version": "0.4.0",
4
4
  "description": "OC Agent signer: createDelegation(), signAsAgent(), revoke(). Composes @orangecheck/agent-core with a wallet-adapter signing function and optional OTS anchoring.",
5
5
  "keywords": [
6
6
  "bitcoin",
@@ -49,13 +49,13 @@
49
49
  },
50
50
  "dependencies": {
51
51
  "@noble/hashes": "^1.5.0",
52
- "@orangecheck/agent-core": "^1.2.0"
52
+ "@orangecheck/agent-core": "^2.1.0"
53
53
  },
54
54
  "devDependencies": {
55
55
  "@types/node": "^22.10.2",
56
56
  "tsup": "^8.3.5",
57
57
  "typescript": "^5.7.2",
58
- "vitest": "^3.2.4"
58
+ "vitest": "^4.1.11"
59
59
  },
60
60
  "publishConfig": {
61
61
  "access": "public"
package/src/index.test.ts CHANGED
@@ -31,7 +31,7 @@ describe('createDelegation', () => {
31
31
  expect(envelope.id).toMatch(/^[0-9a-f]{64}$/);
32
32
  expect(envelope.scopes).toHaveLength(1);
33
33
 
34
- const r = await verifyDelegation({ envelope, verifyBip322: fakeVerify });
34
+ const r = await verifyDelegation({ envelope, verifyBip322: fakeVerify, skipRevocationCheck: true });
35
35
  expect(r.ok).toBe(true);
36
36
  });
37
37
 
@@ -89,6 +89,7 @@ describe('signAsAgent', () => {
89
89
  expect(action.delegation_id).toBe(delegation.id);
90
90
 
91
91
  const r = await verifyAction({
92
+ skipRevocationCheck: true, // offline test — no relay to query
92
93
  action,
93
94
  delegation,
94
95
  verifyBip322: fakeVerify,
@@ -128,7 +129,7 @@ describe('signAsAgent', () => {
128
129
  mime: 'application/pdf',
129
130
  scopeExercised: 'stamp:sign(mime=application/pdf)',
130
131
  });
131
- const r = await verifyAction({ action, delegation, verifyBip322: fakeVerify });
132
+ const r = await verifyAction({ action, delegation, verifyBip322: fakeVerify, skipRevocationCheck: true });
132
133
  expect(r.ok).toBe(false);
133
134
  if (!r.ok) expect(r.code).toBe('E_SCOPE_DENIED');
134
135
  });