import WebSocket from "ws"; import { resolveName, CHIPNET_ELECTRUM } from "../../Argus/src/lib/resolver-web.js"; console.log("electrum pool:", CHIPNET_ELECTRUM.map((s) => (typeof s === "string" ? s : s.url)).join(", ")); for (const n of ["hello.bch","coinspectrum.bch","siatest.bch"]) { const t=Date.now(); try { const e=await resolveName(n,{WebSocket}); console.log(` ${n}: ${e?("OK ["+Object.keys(e.records)+"] "+(Date.now()-t)+"ms"):"NXDOMAIN"}`); } catch(err){ console.log(` ${n}: ERROR ${err.message} (${Date.now()-t}ms)`); } } process.exit(0);