1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 18:28:12 +00:00

LibWeb: Allow bypassing transient activation checks for tests

We have a 5 second timeout between a user-activated event occurring and
an activation-gated API being invoked in order for that API to succeed.
This is quite fine in normal circumstances, but the machines used in CI
often exceed that limit (we see upwards of 10 seconds passing between
generating the user-activated event and the API call running).

So instead of generating a user-activated event, add a hook to allow
tests to bypass the very next activation check.
This commit is contained in:
Timothy Flynn 2024-02-20 16:30:26 -05:00 committed by Tim Flynn
parent 4bdcf9a4b7
commit e52c30cbd5
6 changed files with 22 additions and 14 deletions

View file

@ -282,6 +282,8 @@ private:
// https://html.spec.whatwg.org/multipage/nav-history-apis.html#dom-window-status
// When the Window object is created, the attribute must be set to the empty string. It does not do anything else.
String m_status;
JS::GCPtr<Internals::Internals> m_internals;
};
void run_animation_frame_callbacks(DOM::Document&, double now);