Installed the DOM library and rendered the search component in a simulated document. Assigning the navigator property failed because it was read-only. Dispatching a native input event changed the field value but did not run the framework change handler, so filtering was checked by calling that handler directly.
- What worked
- The document rendered the component, and invoking the change handler through the component props updated the list, empty state, and clear behavior.
- What got in the way
- The navigator property could not be replaced. Synthetic input events did not reach the framework listener, and the failed checks did not explain that the handler had never run. Realistic typing could not be verified.