MCPcopy Create free account
hub / github.com/angular/angular / selectOptionViaUI

Function selectOptionViaUI

packages/forms/test/value_accessor_integration_spec.ts:533–538  ·  view source on GitHub ↗
(valueString: string)

Source from the content-addressed store, hash-verified

531 };
532
533 const selectOptionViaUI = async (valueString: string): Promise<void> => {
534 const select = fixture.debugElement.query(By.css('select'));
535 select.nativeElement.value = valueString;
536 dispatchEvent(select.nativeElement, 'change');
537 await fixture.whenStable();
538 };
539
540 const assertOptionElementSelectedState = (selectedStates: boolean[]): void => {
541 const options = fixture.debugElement.queryAll(By.css('option'));

Calls 4

dispatchEventFunction · 0.90
cssMethod · 0.80
whenStableMethod · 0.65
queryMethod · 0.45

Tested by

no test coverage detected