MCPcopy
hub / github.com/codeceptjs/CodeceptJS / assertFocused

Function assertFocused

lib/helper/extras/richTextEditor.js:121–126  ·  view source on GitHub ↗
(target)

Source from the content-addressed store, hash-verified

119}
120
121async function assertFocused(target) {
122 const focused = await target.evaluate(isActive)
123 if (!focused) {
124 throw new Error('fillField: rich editor target did not accept focus. Locator must point at the visible editor surface (a wrapper, iframe, or contenteditable) — not a hidden backing element.')
125 }
126}
127
128async function findMarked(helper) {
129 const root = helper.page || helper.browser

Callers 1

fillRichEditorFunction · 0.85

Calls 1

evaluateMethod · 0.80

Tested by

no test coverage detected