Rayrun
โ† Back to Discord Forum

how to deal with long ui-tests?

vetsinen_35691posted in #help-playwright
Open in Discord
vetsinen_35691

hello, i need to launch long tests but playwright stops them after 120...ms I set maximal limit by test.setTimeout(2147483647); but it has no any affect

This thread is trying to answer question "How can I resolve Playwright tests stopping after 120 milliseconds even after setting high timeout values?"

12 replies
insane_rookstar
insane_rookstar

120 milliseconds?

vetsinen_35691

yes

Weird, the default timeout is 30s no ?

vetsinen_35691

i updated all limits export default defineConfig({ globalTimeout: 2147483647, timeout: 2147483647, testDir: './tests',

120ms is really fast ๐Ÿ˜… Try 120_000 for 2mins A few minutes might be reasonable if you have a few tests that check long/deep scenarios ratter than many very limited tests.

insane_rookstar
insane_rookstar

What is the error message?

insane_rookstar
insane_rookstar

Maybe it's not related to the timeout, but it just crashing due to some issue in your code.

Did you set expect timeout?

export default defineConfig({ expect: { timeout: 10 * 1000, }, });

refactoreric

Are the await statements missing maybe, for the asynchronous calls? In such case @playwright/test can think the test is finished and teardown the page, the context and the browser.

vetsinen_35691
@mir1412: yes, export default defineConfig({ expect: { timeout: 2147483647, }, testDir: './tests',

yes, export default defineConfig({ expect: { timeout: 2147483647, }, testDir: './tests',

vetsinen_35691
@insane_rookstar: still - Test timeout of 120000ms exceeded. but i cannot understand where from is taken 120000ms

still - Test timeout of 120000ms exceeded. but i cannot understand where from is taken 120000ms

Record a trace, open it in https://trace.playwright.dev and you'll see ๐Ÿ˜‰

Related Discord Threads

TwitterGitHubLinkedIn
AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email [email protected].