/* Socket Lib - Built with esbuild */
var p=Object.defineProperty;var c=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var g=Object.prototype.hasOwnProperty;var l=(r,e)=>{for(var o in e)p(r,o,{get:e[o],enumerable:!0})},d=(r,e,o,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of u(e))!g.call(r,t)&&t!==o&&p(r,t,{get:()=>e[t],enumerable:!(s=c(e,t))||s.enumerable});return r};var y=r=>d(p({},"__esModule",{value:!0}),r);var v={};l(v,{getTypeCoverage:()=>f});module.exports=y(v);var i=require("../spawn");async function f(r){const e={__proto__:null,cwd:process.cwd(),generateIfMissing:!1,...r},{cwd:o,generateIfMissing:s}=e;if(!o)throw new Error("Working directory is required.");try{const t=await(0,i.spawn)("type-coverage",["--detail"],{cwd:o,stdio:["ignore","pipe","pipe"]}),a=t.stdout?t.stdout.toString():"",n=/(\d+) \/ (\d+) ([\d.]+)%/.exec(a);return!n||!n[1]||!n[2]||!n[3]?null:{covered:Number.parseInt(n[1],10),percent:n[3],total:Number.parseInt(n[2],10)}}catch(t){if(s)throw new Error("Unable to generate type coverage. Ensure type-coverage is installed.",{cause:t});return null}}0&&(module.exports={getTypeCoverage});
//# sourceMappingURL=type.js.map
