chore: remove debug trace logs (#2545)

This commit is contained in:
Marvin Hagemeister
2024-06-25 10:08:48 +02:00
committed by GitHub
parent 49839079a4
commit 0f6b4f624f
22 changed files with 150 additions and 8 deletions
+3
View File
@@ -244,6 +244,7 @@ export function parseHtml(input: string): TestDocument {
// deno-lint-ignore no-explicit-any
const doc = new DOMParser().parseFromString(input, "text/html") as any;
Object.defineProperty(doc, "debug", {
// deno-lint-ignore no-console
value: () => console.log(prettyDom(doc)),
enumerable: false,
});
@@ -284,6 +285,7 @@ export function assertMetaContent(
}
if (el === null) {
// deno-lint-ignore no-console
console.log(prettyDom(doc));
throw new Error(
`No <meta>-tag found with content "${expected}"`,
@@ -312,6 +314,7 @@ export async function waitForText(
// deno-lint-ignore no-explicit-any
const pretty = prettyDom(parseHtml(body) as any);
// deno-lint-ignore no-console
console.log(
`Text "${text}" not found on selector "${selector}" in html:\n\n${pretty}`,
);