Reputation: 31
I am not sure if Protractor can sendKeys to a div.
My code is
element(by.css('.create-api-schema-editor .CodeMirror .CodeMirror-lines .CodeMirror-code .CodeMirror-line')).sendKeys(content);
I also tried click first and then sendKeys, but no luck.
HTML is: enter image description here
Upvotes: 0
Views: 402
Reputation: 31
I fixed the issue, we can use browser.actions().click().perform() instead of ele.click().
I am not sure why but it works.
Hope this helpful for you.
Upvotes: 2