import {test,expect,vi} from 'vitest';
function shape(fn){return {type:typeof fn,name:fn.name,length:fn.length,tag:Object.prototype.toString.call(fn),functionPrototype:Object.getPrototypeOf(fn)===Function.prototype,asyncPrototype:Object.getPrototypeOf(fn)===Object.getPrototypeOf(async()=>{}),constructorName:fn.constructor.name,keys:Reflect.ownKeys(fn).map(String),descriptors:Reflect.ownKeys(fn).map(key=>{const d=Object.getOwnPropertyDescriptor(fn,key);return {key:String(key),value:d.value,get:typeof d.get,set:typeof d.set,writable:d.writable??null,enumerable:d.enumerable,configurable:d.configurable}})}}
vi.mock('./root.mjs',importOriginal=>{globalThis.__ws2StaticImportOriginal=importOriginal;return {value:7}});
test('already admitted static importOriginal callback complete function shape',async()=>{const actual=await import('./root.mjs');console.log('WS2_STATIC_CALLBACK_SHAPE:'+JSON.stringify({callback:shape(globalThis.__ws2StaticImportOriginal),value:actual.value,originalEvaluations:globalThis.__ws2StaticOriginalEvaluations??0}));expect(actual.value).toBe(7)});
