dispatch input event

This commit is contained in:
Joao Moreno
2018-04-10 12:19:49 +02:00
parent 37b5661356
commit 43207efb46

View File

@@ -34,7 +34,11 @@ class WindowDriver implements IWindowDriver {
throw new Error('Element not found');
}
(element as HTMLInputElement).value = text;
const inputElement = element as HTMLInputElement;
inputElement.value = text;
const event = new Event('input', { bubbles: true, cancelable: true });
inputElement.dispatchEvent(event);
}
async getTitle(): TPromise<string> {