I fail to find the cause for this error. It seems to be on the 4th line. I have tried various different ways. Could anyone point out where I am going wrong with this pls?
public WebElement jsQuery(String componentQuery) { String cmd = "arguments[0].querySelector('" + componentQuery +"')"; String js = "return " + cmd + ".id;"; // String id = (String) js.executeScript("return document.querySelector('" + componentQuery +"').id"); String id = (String) ((JavascriptExecutor) driver).executeScript(js); waitForJavascript(5000, 3); return driver.findElement(By.id(id)); } https://stackoverflow.com/questions/66037746/javascript-error-missing-after-argument-list February 04, 2021 at 08:29AM
没有评论:
发表评论