Repository navigation
feat(testmuai): @e2e-dev/testmuai, TestMu AI hosted browsers for the web engine - #765
Closed
SahilSawLT wants to merge 4 commits into
Closed
SahilSawLT wants to merge 4 commits into
SahilSawLT wants to merge 4 commits into
Conversation
…web engine testmuai() is a BrowserProvider for @e2e-dev/web that leases TestMu AI (formerly LambdaTest) hosted Chrome and Edge on Windows and macOS. A session starts when its CDP websocket opens, so the provider only builds the CDP URL from the target's options and LT_USERNAME/LT_ACCESS_KEY in the run's environment; it calls no API and release is a no-op. One session per worker slot by default, or per attempt with scope: 'attempt'. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoNxaN1YAAP9PwmHtMm1WX
SahilSawLT
requested review from
okwasniewski and
szymonrybczak
as code owners
October 2, 2026 12:56
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 23 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
- testmuai() rejects unknown keys, a route other than the two routes, a hub with a scheme or path, a non-Chromium browserName, and capabilities that would override user, accessKey, build, name or platform, with INVALID_CONFIG at config load instead of a failed attempt. - idleTimeout defaults to 600 s; the hub otherwise ends a session after 300 s without browser traffic. - Lease ids drop the run id: worker-scope leases share the engine's 16 KB hand-off. Docs state the ~25-worker ceiling, the 60 s connect cap, and what a dropped attempt-scope connection does; browser.mdx lists the provider; the lockfile importer is regenerated. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoNxaN1YAAP9PwmHtMm1WX
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 6 files (changes from recent commits).
Tip: cubic used a learning from your PR history. Let your coding agent read cubic learnings directly with the cubic MCP.
Re-trigger cubic
…CONFIG A JavaScript config can pass null, an array, or a primitive where the types say object: testmuai(null) and capabilities: null threw a raw TypeError, and arrays were accepted. Both now fail with INVALID_CONFIG. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoNxaN1YAAP9PwmHtMm1WX
Sign up or log in to TestMu AI and copy the username and access key from Account Settings > Password & Security. Added to the integration page, the package README, and the environment reference. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoNxaN1YAAP9PwmHtMm1WX
Member
|
Thanks for the PR! This will be superseded by #772 from the TestMu AI team, so we'll consolidate the TestMu AI integration there. Closing for now. |
2 of 5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
@e2e-dev/testmuai:web({ browser: testmuai() })runs a web target in TestMu AI (formerly LambdaTest) hosted Chrome or Edge on Windows and macOS. One session per worker slot, or one per attempt withscope: 'attempt', likekernel().wss://cdp.lambdatest.com/<route>?capabilities=…). There's no SDK and no API call,releaseis a no-op, and@e2e-dev/webis the only peer, like@e2e-dev/eas.LT_USERNAME/LT_ACCESS_KEYare read fromrequest.envand travel only in the CDP URL. The reporter line isTestMu AI session "<name>" in build "<build>", never the URL.scope,browserName,browserVersion,platform,build,route,hub, andcapabilitiesfor furtherLT:Options(video, network, tunnel, idle timeout). Unknown keys, a badroute/hub/browserName, orcapabilitiesthat would override what the provider sets fail withINVALID_CONFIGat config load.idleTimeoutdefaults to 600 s.routedefaults to/puppeteer, which serves raw CDP on every account today./playwright-cdplabels sessions as Playwright on the TestMu AI dashboard; the backend change that makes it serve raw CDP is rolling out, and the default can flip once it reaches production.record,downloadsorsweep: TestMu AI records its own video, downloads land on its machines, and a session a dead worker held ends at TestMu AI's idle timeout. The integration page documents all three.LT:Optionsand theLT_*variable names keep the old brand because they are the service's live contract.sequenceDiagram participant W as web engine participant P as testmuai() participant H as cdp.lambdatest.com W->>P: acquire(request) P-->>W: { id, cdpEndpoint } (caps + LT_* from request.env) W->>H: connectOverCDP(cdpEndpoint) Note over H: socket open = session starts W->>H: close Note over H: socket closed = session ends W->>P: release() (no-op)Verified
Ran it locally: yes
pnpm pack) and installed the tarball into a scratch project one2e0.15.1, soexports/fileswere exercised: the tarball holds onlydist/,LICENSE,NOTICE,README.mdandpackage.json./puppeteer, Windows 11 + Chrome, video on, 3 tests on the-internet.herokuapp.com (taps, assertions, evaluate):workerattemptadd and remove an element: the-internet.herokuapp.com stalls its jQuery for about 30 s on a fresh browser's first load, so the tap lands before the page's script binds. Session, connect and the other assertions are fine; the same test passes when the page is warm.LT_ACCESS_KEYfails before any test withbrowser provider "testmuai" could not lease a browser: LT_USERNAME and LT_ACCESS_KEY must be set, and no session is created.workerscope about 25 workers per target fit the engine's 16 KB lease hand-off (packages/web/src/provider.ts,MAX_HANDOFF_ENV_BYTES; a unit test pins it), and hosts that take more than 60 s to provision (Edge on macOS, for one) fail withconnectOverCDP: Timeout 60000ms exceeded.BROWSER_LAUNCH_TIMEOUT_MSis fixed at 60 s inpackages/web/src/surface.tsandlaunchTimeoutdoesn't reach the CDP connect. Happy to follow up with a separate PR that lets it, if you want that.Checklist
pnpm changeset) for any change to a published package, or the change is testbed, docs, or CI only.docs/integrations/testmuai.mdx, nav, integrations card, environment variables, security (outbound connections), README packages table,AGENTS.md,CONTRIBUTING.md, and theskills/e2esetup row.e2eor@e2e-dev/webcontracts.e2e/engine): n/a.Important
Before merge (maintainers):
@e2e-dev/testmuaiis a new public package. Per CONTRIBUTING.md, publish its first version by hand and connect it torelease.ymlas a trusted publisher; otherwise the next release's publish step fails. If you'd rather land the code first, I can drop the changeset from this PR and add it in a follow-up once the package exists on npm.The changeset takes the package from
0.0.0to aminor, like EAS. The integrations card uses the genericcloudicon until there's a brand SVG to add.🤖 Generated with Claude Code
https://claude.ai/code/session_01KoNxaN1YAAP9PwmHtMm1WX