- contracts: ProvenanceRegistry, AttestationRegistry, SettlementEscrow, MockUSDC (Foundry, OZ AccessControl/SafeERC20/ReentrancyGuard/Pausable), 55 tests - shared: typed ABI/type/address layer (viem, Base Sepolia) - agent: Fastify + Claude tool-calling verification service, deterministic scoring reconciliation, on-chain attest/settle, 73 tests - web: Next.js 15 dApp (wagmi/viem/RainbowKit) — supplier/buyer/verifier/deal, 80 tests - infra: Supabase schema + client, IPFS (Pinata + local fallback), 45 tests - integrated, security + TS reviewed, 18 findings fixed; 314 tests green Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
33 lines
911 B
TypeScript
33 lines
911 B
TypeScript
import { fileURLToPath } from 'node:url';
|
|
import { defineConfig } from 'vitest/config';
|
|
|
|
/**
|
|
* The agent depends on `@proofchain/shared` (a workspace package that is built
|
|
* during the integration phase). To keep this package independently testable —
|
|
* with NO real API key and NO network — tests resolve `@proofchain/shared`
|
|
* to an in-package deterministic test double. See test/doubles/shared.ts and
|
|
* README.md ("Testability").
|
|
*/
|
|
const sharedDouble = fileURLToPath(
|
|
new URL('./test/doubles/shared.ts', import.meta.url),
|
|
);
|
|
|
|
export default defineConfig({
|
|
resolve: {
|
|
alias: {
|
|
'@proofchain/shared': sharedDouble,
|
|
},
|
|
},
|
|
test: {
|
|
globals: true,
|
|
environment: 'node',
|
|
include: ['test/**/*.test.ts'],
|
|
coverage: {
|
|
provider: 'v8',
|
|
reporter: ['text', 'lcov'],
|
|
include: ['src/**/*.ts'],
|
|
exclude: ['src/index.ts', 'src/**/*.d.ts'],
|
|
},
|
|
},
|
|
});
|