docs: split Lambda Hooks into Common / Selenium-only / Playwright-only sections - #3315
Open
SahilSawLT wants to merge 3 commits into
Open
docs: split Lambda Hooks into Common / Selenium-only / Playwright-only sections#3315SahilSawLT wants to merge 3 commits into
SahilSawLT wants to merge 3 commits into
Conversation
…y sections The page listed all hooks in one table with Selenium-only examples and no framework applicability. Reorganized per hook support in the hub proxy's two hook engines (Selenium JavascriptExecutor strings vs the CDP lambdatest_action pattern), documented the Playwright invocation syntax, added the previously-undocumented Playwright-only hooks (setTestStatus, lambda-testCase-start/end, getTestDetails), and fixed hook-name typos (underscores -> actual hyphenated names, lambda-network-throttle -> lambda-throttle-network). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Traced the actual dispatch code (ML_LAMBDA_HOOKS + proxy.go handlers for Selenium; the cdp/proxy.go lambdatest_action dispatch for Playwright) instead of the constants files — many CDP hook constants are defined but never dispatched. Corrections: - lambda-testCase-start/end is COMMON (Selenium string form handled in proxy.go), not Playwright-only - most previously-'common' hooks (file checks, clipboard, ping, throttle, breakpoint, screenshot, keyboard-events, exceptions, name, build) are Selenium-only: their CDP constants have zero dispatch references - Common section rewritten as a capability matrix with the per-framework hook names (lambda-status vs setTestStatus, etc.) - lighthouseReport note: Selenium gets Lighthouse via the performance capability automatically, not via a hook Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ia lambdatest_executor Third Selenium dispatch family found in proxy_ml.go: lambdatest_executor JSON payloads handle lambda-heal-start/stop (also plain-string on the RD path), lighthouseReport, and lambda-accessibility-scan — so lighthouse and accessibility-scan move to Common, and auto-heal (Selenium-only; the CDP path has no heal action) joins the Selenium table linking to the dedicated autoheal-with-hooks page. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Why
The Lambda Hooks page (https://www.testmuai.com/support/docs/lambda-hooks/) lists every hook in one flat table, with all examples in Selenium
JavascriptExecutorsyntax and no indication of which frameworks support which hook. Playwright users can't tell which hooks apply to them or how to invoke them (the Playwright syntax —page.evaluatewith alambdatest_actionpayload — is completely different), and several Playwright-only hooks weren't documented at all.What changed
Reorganized the page into three sections. The classification comes from tracing the hub proxy's actual hook dispatch code for each engine (the Selenium JavascriptExecutor hook list + handlers, and the CDP
lambdatest_actiondispatch), not just constant definitions:lambda-status/setTestStatus), test-case grouping (lambda-testCase-start/end— string form in Selenium, action form in Playwright),lambdaUpdateName,lambda-unbound-pinglambda:network, test-tags); these are not dispatched on the Playwright/CDP pathgetTestDetails,lambdaSetBrowserPosition,lighthouseReport(with a note that Selenium gets Lighthouse automatically via theperformancecapability) — previously undocumented hereAlso:
docs/playwright-testing.md)lambda_breakpoint, …) → the actual hyphenated hook strings;lambda-network-throttle→lambda-throttle-network(the string the grid actually matches)Existing table rows/examples were preserved verbatim wherever they only moved sections. The test-case grouping and
setTestStatusPlaywright examples are verified end-to-end (dashboard annotations render from them).🤖 Generated with Claude Code