tryFocusElement()
Attempts to set input focus to the specified element in the background.
tryFocusElement(element?: TestOutputElement): void;
Notes
- This method is used by the UI element renderer. To acquire input focus, use the UIElement.requestFocus() method instead of calling this method directly.
- Use a poll function or expectOutputAsync() to wait until the element has received input focus.
Parameters
- element — The output element to focus
Related
class TestRenderer
A class that represents an in-memory application render context.
