1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:27:44 +00:00

Tests: Add stub for the internals object when not running in test mode

This allows developers to open LibWeb test html files in Ladybird or in
other browsers to observe their behavior without the internals object.
This commit is contained in:
Andrew Kaster 2023-11-22 09:43:07 -07:00 committed by Andreas Kling
parent bbdf766fb0
commit 79fa892ca1

View file

@ -1,5 +1,11 @@
var __outputElement = null;
if (globalThis.internals === undefined) {
internals = {
signalTextTestIsDone: function () {},
};
}
function println(s) {
__outputElement.appendChild(document.createTextNode(s + "\n"));
}