test('deobfuscates complete error message with imported module',()=>{
constinput=
'(0 , __TURBOPACK__imported__module__$5b$project$5d2f$examples$2f$with$2d$turbopack$2f$app$2f$foo$2e$ts__$5b$app$2d$rsc$5d$__$28$ecmascript$29$__.foo) is not a function'
> 24 | const token = (cookies() as any).get('token')
> 24 | const token = (cookies() as any).get('token')
| ^",
| ^",
"stack": [
"stack": [
"TypeError: {imported module ./nodemodules/.pnpm/next file+..+next-repo-0b36d073ae925c4eba722eaa190867133223877e8e123b2c4d00309ed9b3f21fdbdc34df3c435a7ad1512e006943e153/nodemodules/next/headers.js}.cookies(...).get is not a function",
> 18 | const userAgent = (headers() as any).get('user-agent')
> 18 | const userAgent = (headers() as any).get('user-agent')
| ^",
| ^",
"stack": [
"stack": [
"TypeError: {imported module ./nodemodules/.pnpm/next file+..+next-repo-0b36d073ae925c4eba722eaa190867133223877e8e123b2c4d00309ed9b3f21fdbdc34df3c435a7ad1512e006943e153/nodemodules/next/headers.js}.headers(...).get is not a function",
> 24 | const userAgent = (headers() as any).get('user-agent')
> 24 | const userAgent = (headers() as any).get('user-agent')
| ^",
| ^",
"stack": [
"stack": [
"TypeError: {imported module ./nodemodules/.pnpm/next file+..+next-repo-0b36d073ae925c4eba722eaa190867133223877e8e123b2c4d00309ed9b3f21fdbdc34df3c435a7ad1512e006943e153/nodemodules/next/headers.js}.headers(...).get is not a function",