selenium webdriver getText Returns [object object] selenium webdriver getText Returns [object object] selenium selenium

selenium webdriver getText Returns [object object]


I know this is an old question but, I had the same problem (except using webdriver.io) and the solution was that the [Object object] is actually a Promise object (rather than the String I was expecting -- I was looking at the wrong version of the API). ...getText().then((text)=>{ console.log(text);}); should work.