forked from snxraven/p2ns
Cut over domain resolution to an Autobase apply-based sidecar fed by claim/vote dual-writes from dnsPass. Remove the legacy full-KV scan getConsensusState path and wire all reads through consensus-view. - Add consensus-resolver, consensus-events, consensus-apply, consensus-autobase, and consensus-view modules - Dual-append consensus events on claim/vote dnsPassAdd/Remove - Bootstrap sidecar from existing KV entries; persist consensusAutobaseKey in network manifest - Expose sidecar health via GET /api/consensus/status and metrics - Add consensus-resolver and consensus-apply unit tests - Expand RFC 0001 to Implemented; update CONSENSUS.md Rollback: deploy prior release; KV data unchanged, sidecar rebuilds on next startup.
Smoke tests
These scripts validate core HTTP surfaces on a running P2NS instance.
Prerequisites
- P2NS is running locally and serving internal domains.
- Root certificate is trusted so
https://p2ns.adminandhttps://peer.pasteresolve. - Node.js 18+.
Scripts
npm run test:adminchecksp2ns.adminhealth/status/stats endpoints.npm run test:peer-pastecheckspeer.pastehealth/stats/OpenAPI endpoints.npm run test:pluginscheckspeer.directory,global.profile, andfile.dropAPI endpoints.npm run test:plugin-rpcrunsplugin-channel-rpc.test.js(offline contract tests for protomux-rpc plugin channels; no running node required).npm run test:core-rpcruns core RPC smoke,network-manifest.test.js,core-swarm-handlers.test.js,multi-master.test.js(simulated genesis + N masters, default 4), and invite integration static checks.npm run test:multi-masterruns only the multi-master simulation (MULTI_MASTER_COUNT=6 node test-scripts/multi-master.test.jsto scale).npm testruns admin, peer-paste, and plugins smoke scripts in sequence (does not includetest:plugin-rpcortest:core-rpc).
Custom target URL
You can pass a custom base URL:
node test-scripts/admin-smoke.js https://p2ns.adminnode test-scripts/peer-paste-smoke.js https://peer.paste
You can also override plugin targets with env vars:
PEER_DIRECTORY_URLGLOBAL_PROFILE_URLFILE_DROP_URL