From 0beed258242cff7029ef1806ad0ff4955cb135c1 Mon Sep 17 00:00:00 2001 From: Richard Moore Date: Tue, 14 Jan 2025 13:34:53 -0500 Subject: [PATCH] tests: better runtime exception output for browser tests --- lib.esm/_admin/test-browser.d.ts.map | 2 +- lib.esm/_admin/test-browser.js | 28 +++++++++++++++++++++++++++ lib.esm/_admin/test-browser.js.map | 2 +- src.ts/_admin/test-browser.ts | 29 ++++++++++++++++++++++++++++ 4 files changed, 59 insertions(+), 2 deletions(-) diff --git a/lib.esm/_admin/test-browser.d.ts.map b/lib.esm/_admin/test-browser.d.ts.map index ce02d0f19..046380bb7 100644 --- a/lib.esm/_admin/test-browser.d.ts.map +++ b/lib.esm/_admin/test-browser.d.ts.map @@ -1 +1 @@ -{"version":3,"file":"test-browser.d.ts","sourceRoot":"","sources":["../../src.ts/_admin/test-browser.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;;AAQH,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,CAAC;AAE/B,OAAO,EAAgB,MAAM,EAAE,MAAM,MAAM,CAAC;AAuB5C,wBAAgB,OAAO,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAShD;AAOD,qBAAa,UAAU;;IACnB,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;gBAclB,GAAG,EAAE,MAAM;IA6EvB,IAAI,MAAM,IAAI,MAAM,CAEnB;IAED,IAAI,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC,CAKzB;IAED,IAAI,IAAI,IAAI,OAAO,CAAC,MAAM,CAAC,CAE1B;IAEK,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC;IAO/C,KAAK,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC;IAahD,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAG7C;AAED,MA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,OAAO,CAAC,MAAM,CAAC,CA0GtE"} \ No newline at end of file diff --git a/lib.esm/_admin/test-browser.js b/lib.esm/_admin/test-browser.js index f644512fe..15b2dd21d 100644 --- a/lib.esm/_admin/test-browser.js +++ b/lib.esm/_admin/test-browser.js @@ -111,6 +111,34 @@ export class CDPSession { //console.log(msg.params.message.text, `${ msg.params.message.url }:${ msg.params.message.line }`); } else if (msg.method === "Target.attachedToTarget") { + // Ignore + } + else if (msg.method === "Debugger.scriptParsed") { + // Ignore + } + else if (msg.method === "Debugger.scriptFailedToParse") { + // @TODO: Is this important? It happens a LOT. + } + else if (msg.method === "Runtime.exceptionThrown") { + console.log("Runtime Exception"); + console.log("PARAMS:", msg.params); + let url = ""; + try { + const e = msg.params.exceptionDetails; + url = e.url; + console.log(`Runtime Exception: ${e.text} (${url}:${e.lineNumber}:${e.columnNumber})`); + for (const frame of e.stackTrace.callFrames) { + let loc = `${frame.lineNumber}:${frame.columnNumber}`; + if (frame.url != url) { + url = frame.url; + loc = `${url}:${loc}`; + } + console.log(` - ${frame.functionName} (${loc})`); + } + } + catch (error) { + console.log("ERROR", msg, error); + } } else { console.log(`WARN: Unhandled event - ${JSON.stringify(msg)}`); diff --git a/lib.esm/_admin/test-browser.js.map b/lib.esm/_admin/test-browser.js.map index 84a812534..27bb52729 100644 --- a/lib.esm/_admin/test-browser.js.map +++ b/lib.esm/_admin/test-browser.js.map @@ -1 +1 @@ -{"version":3,"file":"test-browser.js","sourceRoot":"","sources":["../../src.ts/_admin/test-browser.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,gDAAgD;AAEhD,OAAO,EAAE,MAAM,IAAI,CAAC;AACpB,OAAO,aAAa,MAAM,eAAe,CAAC;AAC1C,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,CAAC;AAE/B,OAAO,EAAE,YAAY,EAAU,MAAM,MAAM,CAAC;AAC5C,OAAO,EAAE,IAAI,EAA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AC,IAAI,CAAC,gBAAgB,EAAE,EAAG,CAAC,CAAC;IAC1C,MAAM,OAAO,CAAC,IAAI,CAAC,iBAAiB,EAAE,EAAG,CAAC,CAAC;IAC3C,MAAM,OAAO,CAAC,QAAQ,CAAC,wBAAwB,CAAC,CAAC;IAEjD,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,IAAI,CAAC;IAClC,OAAO,CAAC,GAAG,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;IAC/B,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;AAEzB,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACjB,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;IACrB,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;AACvB,CAAC,CAAC,CAAC"} \ No newline at end of file diff --git a/src.ts/_admin/test-browser.ts b/src.ts/_admin/test-browser.ts index a8bce0f9f..4a1a4edee 100644 --- a/src.ts/_admin/test-browser.ts +++ b/src.ts/_admin/test-browser.ts @@ -137,7 +137,36 @@ export class CDPSession { } console.log(text); //console.log(msg.params.message.text, `${ msg.params.message.url }:${ msg.params.message.line }`); + } else if (msg.method === "Target.attachedToTarget") { + // Ignore + + } else if (msg.method === "Debugger.scriptParsed") { + // Ignore + + } else if (msg.method === "Debugger.scriptFailedToParse") { + // @TODO: Is this important? It happens a LOT. + + } else if (msg.method === "Runtime.exceptionThrown") { + console.log("Runtime Exception"); + console.log("PARAMS:", msg.params); + + let url = ""; + try { + const e = msg.params.exceptionDetails; + url = e.url; + console.log(`Runtime Exception: ${ e.text } (${ url }:${ e. lineNumber }:${ e.columnNumber })`); + for (const frame of e.stackTrace.callFrames) { + let loc = `${ frame.lineNumber }:${ frame.columnNumber}` + if (frame.url != url) { + url = frame.url; + loc = `${ url }:${ loc }` + } + console.log(` - ${ frame.functionName } (${ loc })`); + } + } catch (error) { + console.log("ERROR", msg, error); + } } else { console.log(`WARN: Unhandled event - ${ JSON.stringify(msg) }`); }